body {
  margin: 0;
  width: 100%;
  height: 100%;
  background-color: var(--colorBackground);
  overflow-x: hidden; /* Rimuove la barra di scorrimento orizzontale */
  font-family: var(--font-family-text);
  font-weight: 400;
  font-style: normal;
}

/* =============== Inizio map ===============*/

.container {
  display: grid;
  grid-template-rows: 15vh auto auto auto; 
  row-gap: 3vh;
 
}

/* =============== Inizio nar menu ===============*/

.nar-container {
  display: flex;
  min-height: 40vh;
  height: 30vh;
  width: 100%;
}

.nar-grid {
  display: grid;
  grid-template-rows: 30% 1px auto;
  height: 100%;
  width: 100%;
}

#nar {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr;
}

.nar-but-container {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  width: 100%;
}

/* Main Buttons */
.nar-but {
  font-family: var(--buttons);
  background-color: var(--colorBackground);
  color: var(--text);
  border: 1px solid var(--color5);
  cursor: pointer;
  width: 50%;
  height: 70%;
  max-height: 50px;
  min-width: 180px;
  border-radius: 10px;
  transition: background-color 0.3s ease;
}

.nar-but:hover, .active {
  background-color: var(--color5);
}

#gap {
  justify-self: center;
  height: 1px;
  width: 60%;
  background-color: var(--dividers);
}

#sub-nar {
  display: flex;
  flex-wrap: wrap;
  gap: 5%;
  align-items: center;
  justify-content: center;
  min-height: 12%;
  margin-bottom: 2vh;
}

.sub-nar-but-container {
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translateX(-100vw);
  transition: transform 0.5s ease;
  min-width: 80px;
}

.sub-nar-but {
  font-family: var(--buttons);
  background-color: var(--colorBackground);
  color: var(--text);
  border: 1px solid var(--color5);
  cursor: pointer;
  width: 100%;
  height: 100%;
  padding: 10px;
  border-radius: 10px;
  transition: background-color 0.3s ease;
}

.sub-nar-but:hover {
  background-color: var(--color5);
}

.active {
  background-color: var(--color5);
  
}

/* =============== fine nar menu ===============*/

.content {
  display: grid;
  grid-template-columns: 60vw 30vw;
  gap: 5vw;
  width: 100%;
  padding-bottom: 3vh;
}

.grid-element{
  border-radius: 15px;
}

#map-container {
  width: 100%;
  display: flex; 
  align-items: flex-start;
  justify-content: center; 
  margin-left: 5vh;
  animation: slideInLeft 1s ease-out forwards;
}

#map {
  border-radius: 15px;
  width: 100%; 
  box-shadow: 0 0 10px 5px white;
  
}

/* =========list block========*/

#list-container{
 height: 100%;
 width: 100%;
 animation: slideInRight 1s ease-out forwards;
}

#list-icon{
  display: none;
}

#list {
  padding:0px;
  display: flex;
  justify-content: center;
  height: 100%;
  width: 100%;
  border-radius: 15px;
  min-height: 480px;
}

.itemList{
  margin: 0px;
  width: 100%;
  height:90%;
  color: var(--text);
  font-family:var(--font-family-text) ;
}

.itemList li::marker {
  font-size: 1.5em; 
  color:var(--color4);   
}

.itemList li {
  cursor: pointer; 
  transition: border 0.2s ease, background-color 0.2s ease; 
}

.itemList li:hover {
  color: var(--color4); 
  border-radius: 5px; 
  background-color: var(--color6); 
}

@keyframes slideInLeft {
  from {
    transform: translateX(-100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes slideInRight {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}


@media screen and (max-width: 830px) {

  .nar-grid{
    gap:0;
  }

  .nar-but{
    min-width: fit-content;
    min-height:42.55px ;
  }

  #sub-nar {
    gap: 2%; 
  }

  .sub-nar-but {
    width: 100%;
    height: 100%;
    max-height: 42.55px;
  }
  
  .content {
    display: grid;
    grid-template-columns: 1fr; 
    grid-template-rows: auto auto; 
    padding-bottom: 0;
  }
  
  #map-container {
    height: fit-content; 
    margin-left: 0vh;
  }

  #list {
   align-items: flex-start;
  }
  
}
/* =============== Fine map ===============*/
  
  
  