/*variables*/
:root {
  color-scheme: light dark;

  --accent: #06d892;
  --accent-darker: hsl(from var(--accent) h s calc(l - 35));
  --accent-lmoins30: hsl(from var(--accent) h s calc(l - 30));
  --accent-lmoins20: hsl(from var(--accent) h s calc(l - 20));
  --accent-smoins10: hsl(from var(--accent) h calc(s - 10) l);
  --accent-splus10: hsl(from var(--accent) h calc(s + 10) l);
  --accent-splus20: hsl(from var(--accent) h calc(s + 20) l);
  --accent-splus30: hsl(from var(--accent) h calc(s + 30) l);
  --accent-splus40: hsl(from var(--accent) h calc(s + 40) l);
  --accent-splus50: hsl(from var(--accent) h calc(s + 50) l);


  --black: black;

  --grey111: #111;
  --grey222: #222;
  --grey333: #333;

  --grey666: #666;
  --grey999: #999;

  --greyCCC: #CCC;
  --greyDDD: #DDD;
  --greyEEE: #EEE;

  --white: white;
  

  --light-blue: lightblue;
  --dark-blue: steelblue;

}

/* body */

body {
  font-family: sans-serif;
  background-color: light-dark(#FFF9EB, var(--black));
  margin: 0;
}


/* header */

#page-accueil-active header,
#page-journal-active header,
#page-photos-active header,
#page-carte-active header,
#page-contact-active header {
  background-color: light-dark(var(--accent-splus20), var(--accent-darker));
  width: 100%;
  height: 150px;
  @media (width > 500px) {
    height: 130px;
  }
  @media (width > 800px) {
    height: 60px;
    display: flex;
  }
}

h1 {
  font-size: 2em;
  a {
    color: light-dark(var(--accent-darker), var(--accent));
    text-decoration: none;
    &:hover {color: light-dark(var(--black), var(--accent-splus10));}
  }
}

#page-accueil-active h1,
#page-journal-active h1,
#page-photos-active h1,
#page-carte-active h1,
#page-contact-active h1 {
  margin: 0;
  text-align: center;
  line-height: 35px;
  margin-left: 1.3em;
  margin-right: 1.3em;
  padding-top: 10px;
  @media (500px >= width > 450px ) {
    margin-left: 2em;
    margin-right: 2em;
  }
  @media (width > 500px) {
    line-height: 60px;
    padding-top: 0;
  }
  @media (width > 800px) {
    margin-left: 1em;
    text-align: unset;
  }
}


/* nav */

nav a {
  text-decoration: none;
  &:any-link {color: light-dark(var(--black), var(--white));}
}

.barrenav {
  display: flex;
  flex-wrap: wrap;
  list-style-type: none;
  margin-left: -2.5em;
  justify-content: center;
  gap: 10px;
  margin-top: 10px;
}

.elementnav {
  text-align: center;
  margin: auto;
  display: inline-block;
  line-height: 40px;
  width: 150px;
  border-radius: 20px;
  background-color: light-dark(var(--accent), var(--accent-lmoins30));
  &:hover {
    background-color: light-dark(var(--accent-splus50), var(--accent));
    color: black;
  }
  @media (width < 1300px) {
    width: 40px;
  }
}

#page-accueil-active #bouton-accueil,
#page-journal-active #bouton-journal,
#page-photos-active #bouton-photos,
#page-carte-active #bouton-carte,
#page-contact-active #bouton-contact {
  background-color: light-dark(var(--accent-splus50), var(--accent));
  color: var(--black);
}

#page-accueil-active nav,
#page-journal-active nav,
#page-photos-active nav,
#page-carte-active nav,
#page-contact-active nav {
  height: 100px;
  align-content: center;
  height: 25px;
}

.texte-nav {
  @media (width < 1300px) {
    display: none;
  }
}


/* main */

.home-main,
.journal-main,
.photos-main,
.carte-main,
.contact-main {
  padding: 1em;
}

.journal-main,
.photos-main {
  padding-top: 0;
}


/* aside + section */

.journal-aside,
.journal-section,
.photos-aside,
.photos-section {
  padding-top: 1em;
  @media (width > 800px) {
    padding-top: 2em;
  }
}

@media (width > 1000px) {

  .journal-aside,
  .journal-section,
  .photos-aside,
  .photos-section {
    position: fixed;
    height: 90vh;
    overflow-y: auto;
  }

  .journal-aside,
  .photos-aside {
    width: 21em;
    padding-left: 1em;
    padding-right: 1em;
  }

  .journal-section,
  .photos-section {
    margin-left: 23em;
    padding-right: 2em;
    padding-left: 1em;
  }
}


/* aside */

.accordeon {
  background-color: light-dark(var(--white), var(--grey111));
  color: light-dark(var(--black), var(--white));
  border-radius: 10px;
  box-shadow: 0px 0px 10px light-dark(#DDD, #000);
  margin-bottom: 1em;

  summary {
    font-weight: bold;
    margin: -0.5em -0.5em 0;
    padding: 0.5em;
    cursor: pointer;
    font-size: 1.1em;
    text-align: center;
  }

  details {
    &:last-child {
      border: none;
      padding-bottom: 1px;
    }
    border-bottom: 1px solid light-dark(var(--greyCCC), var(--grey333));
    padding: 0.5em 0.5em 0;

    &[open] summary {
      margin-bottom: 0.5em;
    }
  }
}

.photos-filtres {
  margin-bottom: 30px;
  text-align: center;
}

.photos-boutons-filtre {
  background-color: #DDD;
  padding: 10px 20px;
  border-radius: 20px;
  color: black;
  text-decoration: none;
}

/* calendrier */

.selection-mois {
    margin: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.calendar-container {
    margin: auto;
    width: 310px;
    @media (width <= 500px) {
        width: 100%;
    }
}

.header-display {
    display: flex;
    align-items: center;
}

.header-display p {
    color: light-dark(var(--black), var(--white));
    margin: 5px;
    font-size: 1.2rem;
    word-spacing: 0.5rem;
    font-weight: bold;
}

.display {
    a:any-link {
        color: light-dark(var(--black), var(--white));
        text-decoration: none;
    }
}

pre {
    padding: 10px;
    margin: 0;
    cursor: pointer;
    font-size: 1.2rem;
    color: light-dark(var(--accent-darker), var(--accent));
}

.days, .week {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    margin: auto;
    row-gap: 10px;
    justify-items: center;
}

.week {
    color: light-dark(var(--accent-darker), var(--accent));
    padding-bottom: 10px;
    margin-top: -10px;
}

.days {
    color: light-dark(var(--accent-darker), var(--accent));
}

.week div, .days a {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 40px;
    width: 40px;
    @media (width <= 400px) {
      height: 35px;
      width: 35px;
    }
}

.days a:any-link {
    text-decoration: none;
    color: light-dark(var(--accent-darker), var(--accent));
}

.days a {
    background-color: light-dark(var(--accent-splus40), var(--accent-darker));
    border-radius: 20px;
}

.days a:hover {
    background-color: light-dark(var(--accent), var(--accent));
    color: light-dark(var(--accent-darker), var(--accent-darker));
}

.current-date {
    background-color: var(--accent);
    color: var(--background);
}


/* section */

article {
  max-width: 56em;
  border-radius: 10px;
  box-shadow: 0px 0px 10px light-dark(#DDD, #000);
  padding: 1em;
  margin: auto;
  background-color: light-dark(var(--white), var(--grey111));
  margin-bottom: 1em;
  @media (width > 800px) {
    padding: 2em;
  }
}


/* bloc accueil */

.blocs-articles-photos {
  display: flex;
  flex-direction: column;
  max-width: 1000px;
  margin: auto;
  @media (width > 800px) {
    flex-direction: row;
  }
}

.bloc-gauche,
.bloc-droit {
  flex: 1;
}

.bloc-gauche {
  @media (width > 800px) {
    margin-right: 2em;
  }
}

.accueil-bloc {
  display: flex;
  flex-direction: column;
  padding-top: 1em;
  margin-bottom: 1em;
  @media (width > 800px) {
    padding: 2em;
    margin-bottom: 2em;
  }
}

h4 {
  font-weight: bold;
  font-size: 1.3em;
  margin: 0;
}

.liste-articles {
  margin-bottom: 0;
}

.lien-article {
  font-family: sans-serif;
  color: light-dark(black, white);
  text-decoration: none;
  li {
    background-color: light-dark(white, var(--grey111));
    box-shadow: 0px 0px 10px light-dark(var(--greyEEE), var(--grey333));
    transition: 0.3s;
    border-radius: 10px;
    padding: 1em;
    margin-bottom: 1em;
    p {
      margin: 0;
    }
    &:hover {
      box-shadow: 0px 0px 20px light-dark(var(--greyDDD), var(--grey666));
      transition: 0.3s;
    }
  }
  .titre {
    font-weight: bold;
    font-size: 1.2em;
    margin-bottom: 10px;
  }
  .date {
    background-color: light-dark(#f2f2f2, var(--grey222));
    padding: 7px;
    width: 100px;
    height: 1em;
    line-height: 1em;
    border-radius: 8px;
    font-size: 0.9em;
  }
}

.total-articles,
.total-photos {
  text-decoration: none;
  text-align: center;
  color: black;
  background-color: var(--accent-splus20);
  border-radius: 2em;
  padding: 10px;
  height: 1em;
  line-height: 1em;
  font-size: 0.9em;
  transition: 0.3s;
  p {
    margin: 0;
  }
  &:hover {
    background-color: var(--accent-splus40);
    box-shadow: 0px 0px 5px var(--accent);
    transition: 0.3s;
  }
}

.total-articles {
  width: 150px;
}

.total-photos {
  width: 200px;
}

ul {
  list-style: none;
}

.liste-photos {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 0px;
  margin-top: 1em;
}

.liste-photos>li {
  position: relative;
}

.liste-photos li span,
.liste-photos li a {
  margin: 5px 5px 0px 5px;
}

.liste-photos::after {
  /* content: ""; */
  flex-basis: 350px;
}

.liste-photos li img,
.liste-photos li video {
  object-fit: contain;
  max-width: 100%;
  max-height: 35svh;
  vertical-align: middle;
  border-radius: 5px;
  @media (orientation: portrait) {
    max-height: 75svh;
  }
}

.liste-photos li img {
  min-height: 200px;
}

.liste-photos li video {
  min-height: 180px;
}

.overlay {
  position: absolute;
  top: 0;
  left: 0;
  transform: scale(0);
  color: var(--white);
  border-radius: 5px;
  display: flex;
  flex-wrap: wrap;
  flex-direction: column;
  align-items: start;
  a:any-link {
    color: var(--white);
    text-decoration: none;
  }
}

.completedate,
.zoom {
  background-color: rgba(0, 0, 0, 0.7);
  border-radius: 20px;
  padding: 5px 10px 5px 10px;
  font-size: 0.9em;
}

.liste-photos li:hover .overlay {
  transform: scale(1);
}


/* article */

article ul,
article ol {
  color: light-dark(var(--black), var(--white));
  font-family: serif;
  padding: 0px;
}

article ol {
  margin-left: 1em;
}

.texte-article {
  color: light-dark(var(--black), var(--white));
  font-family: serif;
  font-size: 1em;
  margin-top: 0;
  a {
    color: light-dark(var(--dark-blue), var(--light-blue));
  }
  &:last-child {
    margin-bottom: 0;
  }
}




/* titre article, h3 */

.titre-article,
.journal-h3,
.photos-h3 {
  text-align: center;
  font-size: 2em;
  color: light-dark(var(--black), var(--white));
  margin: 0 0.5em 0.5em 0.5em;
}

.journal-h3,
.photos-h3 {
  margin-top: 0;
  margin-bottom: 0.5em;
}


/* données de l'article */

.donnees-page {
  display: flex;
  flex-wrap: wrap;
  column-gap: 10px;
  row-gap: 10px;
  line-height: 35px;
  margin-bottom: 25px;
  justify-content: center;
  color: light-dark(var(--black), var(--white));
  text-align: center;
  a:any-link {
    text-decoration: none;
    color: white;
  }
  /* @media (orientation: portrait) {
    flex-direction: column;
  } */
}


/* précisions sur chaque données */

.journal-vers-photos,
.photos-bouton-photos,
.photos-bouton-videos,
.photos-bouton-journal {
  border-radius: 20px;
  background-color: light-dark(var(--greyDDD), var(--grey333));
  text-decoration: none;
  color: light-dark(var(--black), var(--white));
  padding: 0px 20px 0px 20px;
  &:hover {
    background-color: light-dark(var(--greyEEE), var(--grey222));
  }
}

.photos-pasdephotos {
  border-radius: 20px;
  background-color: #222;
  color: white;
  padding: 0px 20px 0px 20px;
}

.journal-donnee-date,
.journal-donnee-pays,
.journal-donnee-ville {
  border-radius: 10px;
  background-color: light-dark(var(--greyEEE), var(--grey222));
  padding: 0px 15px 0px 15px;
}

#tag-photo .photos-bouton-photos,
#tag-video .photos-bouton-videos {
  background-color: var(--accent);
  color: black;
}


/* photos journal*/

.photos,
.grandesphotos {
  display: flex;
  flex-wrap: wrap;
  justify-content: start;
  column-gap: 5px;
}

.photos img,
.photos video {
  max-height: 60svh;
  max-width: 100%;
  border-radius: 5px;
  margin: 0px 0px 5px 0px;
}

.grandesphotos img,
.grandesphotos video {
  max-height: 60svh;
  max-width: 100%;
  border-radius: 5px;
  margin: 0px 5px 5px 0px;
}

.legende {
  margin-top: 0px;
  color: light-dark(var(--grey666), var(--grey999));
  font-family: serif;
  font-style: italic;
  a {
    color: light-dark(var(--grey666), var(--grey999));
  }
}


/* Videos journal */

.videos,
.grandesvideos {
  display: flex;
  flex-wrap: wrap;
  max-height: 75svh;
  margin: 0px 5px 5px 0px;
}

.grandesvideos {
  max-width: 100%;
}

.videos {
  max-width: 49%;
  @media (orientation: portrait) {
    max-width: 100%;
  }
}


/* page photos */

.popupImage {
  max-height: 200px;
}

.pagination {
  text-align: center;
  margin-top: 20px;
}

.page-active,
.page-inactive,
.interpage {
  display: inline-block;
  text-decoration: none;
  line-height: 40px;
  width: 40px;
  border-radius: 40px;
}

.page-active:hover,
.page-inactive:hover {
  background-color: var(--accent-splus10);
  color: var(--black);
}

.page-active {
  background-color: var(--accent);
  color: var(--black);
}

.page-inactive {
  background-color: light-dark(var(--greyDDD), var(--grey222));
  color: light-dark(var(--black), var(--white));
}

.interpage {
  background-color: light-dark(var(--greyEEE), var(--grey111));
  color: light-dark(var(--black), var(--white));
}


/* galerie photos */

ul {
  list-style: none;
}

.image-gallery {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 0px;
  margin: 0;
}

.image-gallery>li {
  position: relative;
}

.image-gallery li span,
.image-gallery li a {
  margin: 5px 5px 0px 5px;
}

.image-gallery::after {
  /* content: ""; */
  flex-basis: 350px;
}

.image-gallery li img,
.image-gallery li video {
  object-fit: contain;
  max-width: 100%;
  max-height: 30svh;
  vertical-align: middle;
  border-radius: 5px;
  @media (orientation: portrait) {
    max-height: 75svh;
  }
}

.image-gallery li img {
  min-height: 200px;
}

.image-gallery li video {
  min-height: 180px;
}

.overlay {
  position: absolute;
  top: 0;
  left: 0;
  transform: scale(0);
  color: var(--white);
  font-family: sans-serif;
  border-radius: 5px;
  display: flex;
  flex-wrap: wrap;
  flex-direction: column;
  align-items: start;
  a:any-link {
    color: var(--white);
    text-decoration: none;
  }
}

.completedate,
.caption,
.localisation,
.camera,
.zoom {
  background-color: rgba(0, 0, 0, 0.7);
  border-radius: 20px;
  padding: 5px 10px 5px 10px;
  font-size: 0.9em;
}

.image-gallery li:hover .overlay {
  transform: scale(1);
}

.lazyload {
	opacity: 0;
  transition: opacity 0.3s;
}

.lazyload.loaded {
	opacity: 1;
}


/* Photos individuelles */

.section-photo-ind {
  position: relative;
  z-index: 1;
  max-width: 90%;
  border-radius: 10px;
  border: 1px solid #333;
  padding: 25px 25px 25px 25px;
  margin: auto;
  margin-top: 25px;
  background-color: #111;
}

.page-photo-ind {
  display: flex;
  flex-wrap: wrap;
  column-gap: 10px;
  row-gap: 10px;
}

.photo-individuelle {
  max-width: 100%;
  max-height: 80svh;
  flex: 1;
  border-radius: 10px;
  object-fit: contain;
}

.donnees-photo-ind {
  color: light-dark(var(--black), var(--white));
  flex: 1;
  min-width: 200px;
}

.donnee-photo-date,
.donnee-photo-camera,
.donnee-photo-caption {
  border-radius: 10px;
  background-color: light-dark(var(--greyDDD), var(--grey222));
  padding: 10px 20px 10px 20px;
  text-decoration: none;
  display: inline-block;
  margin: 0px 5px 10px 0px;
}

.carte-photo-ind {
  z-index: 1;
  max-height: 50svh;
  height: 500px;
  max-width: 100%;
  border-radius: 10px;
}


/* cartes */

.cartes {
  max-height: 75svh;
  height: 500px;
  max-width: 100%;
  border-radius: 5px;
  margin: 0px 5px 5px 0px;
}

#cartephoto {
  z-index: 1;
  max-height: 50svh;
  height: 500px;
  max-width: 100%;
  border-radius: 10px;
  margin-bottom: 0.7em;
}


/* Bouton retour en haut */

#bouton-retour-haut {
  text-align: center;
  text-decoration: none;
  color: var(--black);
  position: fixed;
  float: right;
  bottom: 20px;
  right: 20px;
  width: 60px;
  height: 54px;
  font-size: 34px;
  background-color: var(--accent);
  border-radius: 30px;
  padding: 6px 0px 0px 0px;
  z-index: 99;
  &:hover {
    background-color: var(--accent-splus10);
  }
}


/* Traductions */

.espagnol {
  position: relative;
  display: inline-block;
  border-bottom: 1px dotted light-dark(var(--accent-smoins10), var(--accent));
  color: light-dark(var(--accent-smoins10), var(--accent));
}

.espagnol .traduction {
  visibility: hidden;
  background-color: var(--accent);
  color: var(--black);
  text-align: center;
  font-weight: bold;
  border-radius: 6px;
  padding: 5px 10px;
  position: absolute;
  z-index: 1;
  bottom: 125%;
  left: 50%;
  margin-left: -60px;
  opacity: 0;
  transition: opacity 0.3s;
}

.espagnol .traduction::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 50%;
  margin-left: -5px;
  border-width: 5px;
  border-style: solid;
  border-color: var(--accent) transparent transparent transparent;
}

.espagnol:hover .traduction {
  visibility: visible;
  opacity: 1;
}


/* Navigation entre les jours */

.changement-jour {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin: 25px 0px;
  a {
    background-color: var(--accent);
    border-radius: 40px;
    text-align: center;
    &:any-link {
      text-decoration: none;
      color: var(--black);
    }
    &:hover {
      background-color: var(--accent-splus10);
    }
  }
  .gauche, .droit {
    min-width: 110px;
  }
  .centre {
    width: 250px;
  }
}

.bouton-changement-jour {
  line-height: 20px;
  margin: 0px;
  padding: 10px 15px 10px 15px;
}




/* footer */

footer {
  text-align: center;
  color: light-dark(var(--black), var(--white));
  font-size: 0.8em;
}