/*========== GOOGLE FONTS ==========*/
@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600&display=swap");

/*========== VARIABLES CSS ==========*/
:root {
  --header-height: 3.5rem;
  --nav-width: 219px;

  /*========== Colors ==========*/
  --first-color: #298033;
  --first-color-light: #e9f0e9;
  --title-color: #19181B;
  --text-color: #58555E;
  --text-color-light: #A5A1AA;
  --body-color: #F9F6FD;
  --container-color: #FFFFFF;

  /*========== Font and typography ==========*/
  --body-font: 'Poppins', sans-serif;
  --normal-font-size: .938rem;
  --small-font-size: .75rem;
  --smaller-font-size: .75rem;

  /*========== Font weight ==========*/
  --font-medium: 500;
  --font-semi-bold: 600;

  /*========== z index ==========*/
  --z-fixed: 100;
}

@media screen and (min-width: 1024px) {
  :root {
    --normal-font-size: 1rem;
    --small-font-size: .875rem;
    --smaller-font-size: .813rem;
  }
}

/*========== BASE ==========*/
*, ::before, ::after {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  height: 100%; /* Assure que le body occupe toute la hauteur de l'écran */
  display: flex;
  flex-direction: column; /* Dispose le contenu en colonne */
}

body {
  margin: var(--header-height) 0 0 0;
  padding: 1rem 1rem 0;
  font-family: var(--body-font);
  font-size: var(--normal-font-size);
  background-color: white;
  color: var(--text-color);
}




/* Ajoutez ces règles pour la section */
/* 
section {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 5%;
  margin: 5%;
  max-width: 100%;
}
*/





h3 {
  margin: 0;
}

a {
  text-decoration: none;
}
    .hidden-button {
        background: none;
        border: none;
        padding: 0;
        cursor: pointer;
        outline: none;
    }

    .hidden-button .bx {
        font-size: 1.5vw; /* Utilisation de vw pour la taille réactive */
    }
	    @media (max-width: 768px) {
        .hidden-button .bx {
            font-size: 20px; /* Ajustez la taille pour les écrans petits */
        }
    }

    @media (max-width: 480px) {
        .hidden-button .bx {
            font-size: 30px; /* Ajustez la taille pour les écrans encore plus petits */
        }
    }



/* Style pour le texte "Déposer une annonce" */
.deposer-annonce {
  display: block; /* Par défaut, affiche le texte */
}

/* Media query pour les petits écrans où le texte sera masqué */
@media screen and (max-width: 768px) {
  .deposer-annonce {
    display: none; /* Masque le texte pour les petits écrans */
  }
}

/* Style pour le titre "Déposer une annonce" */
.deposer-titre {
  display: none; /* Par défaut, masque le titre */
}

/* Media query pour les petits écrans où le titre sera affiché */
@media screen and (max-width: 768px) {
  .deposer-titre {
    display: block; /* Affiche le titre pour les petits écrans */
  }
}


/*centrer la publication d'annonce*/
        section {
            width: 40%;
            height: auto;
            margin: 0 auto; /* Ceci centrera horizontalement la section */
        }
		

		        /* Styles pour la section sur les petits écrans */
        @media (max-width: 1368px) {
            section {
                width: auto;
                margin: 0; /* Annuler la marge horizontale pour les petits écrans */
            }
        }



img {
  max-width: 100%;
  height: auto;
}

/*========== HEADER ==========*/
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: var(--container-color);
  box-shadow: 0 1px 0 rgba(22, 8, 43, 0.1);
  padding: 0 1rem;
  z-index: var(--z-fixed);
}

.header__container {
  display: flex;
  align-items: center;
  height: var(--header-height);
  justify-content: space-between;
}

.header__img {
  width: 35px;
  height: 35px;

}

.header__logo {
	
  color: var(--title-color);
  font-weight: var(--font-medium);
  
}

.header__search {
  display: flex;
  padding: .40rem .75rem;
  background-color: var(--first-color-light);
  border-radius: .25rem;
}

.header__input {
  width: 100%;
  border: none;
  outline: none;
  background-color: var(--first-color-light);
}

.header__input::placeholder {
  font-family: var(--body-font);
  color: var(--text-color);
}




.header__icon{
  font-size: 1.2rem;
}
.header__toggle {
  font-size: 2.2rem;
  margin-top: 8px;
}

.header__toggle {
  color: var(--title-color);
  cursor: pointer;
}



@media screen and (min-width: 769px) {
    .header__logo-img {
        display: inline-block; /* Show the logo on medium and large screens */
        max-width: 90px; /* Adjust the width of the logo for medium and large screens */
        margin-right: 10px; /* Add some spacing if needed */
    }
    .header__logo {
        display: none; /* Hide the text logo on medium and large screens */
    }
}


/*========== NAV ==========*/
.nav {
  position: fixed;
  top: 0;
  left: -100%;
  height: 100vh;
  padding: 1rem 1rem 0;
  background-color: var(--container-color);
  box-shadow: 1px 0 0 rgba(22, 8, 43, 0.1);
  z-index: var(--z-fixed);
  transition: .4s;
}



.nav__container {
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding-bottom: 3rem;
  overflow: auto;
  scrollbar-width: none; /* For mozilla */
}

/* For Google Chrome and others */
.nav__container::-webkit-scrollbar {
  display: none;
}

.nav__logo {
  font-weight: var(--font-semi-bold);
  margin-bottom: 2.5rem;
}

.nav__list, 
.nav__items {
  display: grid;
}

.nav__list {
  row-gap: 2.5rem;
}

.nav__items {
  row-gap: 1.5rem;
}

.nav__subtitle {
  font-size: var(--normal-font-size);
  text-transform: uppercase;
  letter-spacing: .1rem;
  color: var(--text-color-light);
}

.nav__link {
  display: flex;
  align-items: center;
  color: var(--text-color);
}

.nav__link:hover {
  color: var(--first-color);
}

.nav__icon {
  font-size: 1.2rem;
  margin-right: .5rem;
}

.nav__name {
  font-size: var(--small-font-size);
  font-weight: var(--font-medium);
  white-space: nowrap;
  
}

.nav__logout {
  margin-top: 5rem;
  padding-bottom:10px;
}

/* Dropdown */
.nav__dropdown {
  overflow: hidden;
  max-height: 21px;
  transition: .4s ease-in-out;
}

.nav__dropdown-collapse {
  background-color: var(--first-color-light);
  border-radius: .25rem;
  margin-top: 1rem;
}

.nav__dropdown-content {
  display: grid;
  row-gap: .5rem;
  padding: .75rem 2.5rem .75rem 1.8rem;
}

.nav__dropdown-item {
  font-size: var(--smaller-font-size);
  font-weight: var(--font-medium);
  color: var(--text-color);
}

.nav__dropdown-item:hover {
  color: var(--first-color);
}

.nav__dropdown-icon {
  margin-left: auto;
  transition: .4s;
}

/* Show dropdown collapse */
.nav__dropdown:hover {
  max-height: 100rem;
}

/* Rotate icon arrow */
.nav__dropdown:hover .nav__dropdown-icon {
  transform: rotate(180deg);
}

/*===== Show menu =====*/
.show-menu {
  left: 0;
}

/*===== Active link =====*/
.active {
  color: var(--first-color);
}

/* ========== MEDIA QUERIES ==========*/
/* For small devices reduce search*/
@media screen and (max-width: 320px) {
  .header__search {
    width: 100%;
  }
}

@media screen and (min-width: 768px) {
  body {
    padding: 1rem 3rem 0 6rem;
  }
  .header {
    padding: 0 3rem 0 6rem;
	
  }
  .header__container {
    height: calc(var(--header-height) + .5rem);
  }
  .header__search {
    width: 300px;
    padding: .55rem .75rem;
  }
  .header__toggle {
    display: none;
  }
  .header__logo {
    display: block;
  }
  .header__img {
    width: 130px;
    height: auto;
    order: 1;
  }
  .nav {
    left: 0;
    padding: 1.2rem 1.5rem 0;
    width: 68px; /* Reduced navbar */
	
  }
  .nav__items {
    row-gap: 1.7rem;
  }
  .nav__icon {
    font-size: 1.3rem;
  }

  /* Element opacity */
  .nav__logo-name, 
  .nav__name, 
  .nav__subtitle, 
  .nav__dropdown-icon {
    opacity: 0;
    transition: .3s;
  }
  
  
  /* Navbar expanded */
  .nav:hover {
    width: var(--nav-width);
  }
  
  /* Visible elements */
  .nav:hover .nav__logo-name {
    opacity: 1;
  }
  .nav:hover .nav__subtitle {
    opacity: 1;
  }
  .nav:hover .nav__name {
    opacity: 1;
  }
  .nav:hover .nav__dropdown-icon {
    opacity: 1;
  }
}

        .hidden {
            display: none;
        }

