body{
    margin:0;
    padding:0;
    font-family: 'Inter', sans-serif;
    height:100svh;
    overflow: hidden;
}
h3, h2, h1{margin:10px 0}
#indexbody {
			margin: 0;
			padding: 0;
			background-image: url('fons.jpg');
			background-size: cover;           /* Omple tota l'àrea disponible */
			background-repeat: no-repeat;     /* No es repeteix */
			background-position: center center; /* Centrada verticalment i horitzontalment */
			background-attachment: fixed;     /* Opcional: fixa el fons mentre fas scroll */
			height: 100vh; 			/* Assegura que el body ocupi tota la pantalla */
			font-size:12px;
		}
		
        a.button {
            display: flex;
            justify-content:space-between;
            align-items: center;  
            text-align: center;
            padding: 10px 14px;
            color: black;
            text-decoration: none;
            font-size: 16px;        }

       

        table {
            width: 100%;
            margin: 0 auto;
            border-collapse: collapse;
            box-shadow: 0 2px 5px rgba(0,0,0,0.1);
        }

        th, td {
            padding: 12px;
            text-align: left;
            border-bottom: 1px solid #ddd;
            vertical-align: middle;
        }

        th {
            background-color: #f4f4f4;
            font-weight: bold;
        }

        tr:hover {
            background-color: #f9f9f9;
        }

        .visited {
            background-color: #e6ffe6; /* Verd clar */
        }

        

        .check-btn, .info-btn {
            background: none;
            border: none;
            cursor: pointer;
            font-size: 16px;
            margin-right: 5px;
        }

        .modal {
            display: none;
            position: fixed;
            z-index: 10;
            left: 0;
            top: 0;
            width: 100%;
            height: 100%;
            overflow: auto;
            background-color: rgba(0,0,0,0.4);
        }

        .modal-content {
            background-color: #fff;
            margin: 10% auto;
            padding: 20px;
            border-radius: 8px;
            width: 90%;
            max-width: 600px;
            box-shadow: 0 5px 15px rgba(0,0,0,0.3);
        }

        .close-modal {
            float: right;
            font-size: 20px;
            font-weight: bold;
            cursor: pointer;
        }

        
		
	.login-container {
            width:60%;
            margin:50px 20%;
            background-color: #fff;
	        padding: 20px;
            box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
            border-radius: 8px;
            box-sizing: border-box;
            background-color: #fff;
	}

	.login-container h1 {
		text-align: center;
	}

	.login-container label {
		display: block;
		margin: 10px 0 5px;
	}

	.login-container input[type="email"],
	.login-container input[type="password"],
	.login-container input[type="text"] {
		width: 95%;
		padding: 8px;
		margin-bottom: 10px;
		border: 1px solid #ddd;
		border-radius: 4px;
	}

	.login-container button {
		width: 100%;
		padding: 10px;
		background-color: #007BFF;
		color: white;
		border: none;
		border-radius: 4px;
		cursor: pointer;
	}

	.login-container button:hover {
		background-color: #0056b3;
	}

	.login-container p {
		text-align: center;
		margin-top: 15px;
	}

	.login-container a {
		color: #007BFF;
		text-decoration: none;
	}

	.login-container a:hover {
		text-decoration: underline;
	}
	
	
	.municipi-container {
        overflow-y: scroll;
    }

.municipi-container h1 {
    color: #333;
}

.tresor-container { 
    background-color: #fff;
    outline: none; /* Elimina el contorn */
    overflow-y:scroll;
    position: absolute;
    top: 70px;
    box-sizing: border-box;
    left:20%;
    width: 80%;
}

.tresor-container img { 
    margin: 10px auto; 
    display: block;
    
}

.capestresor{
    width:90%;
    margin:20px auto;
    padding:15px;
    box-sizing: border-box ;
}
.error-message { color: red; font-weight: bold; margin: 20px; }





.inici-container { 
	display:flex;
	flex-direction:row;
	justify-content:flex-between;
    flex-wrap:wrap;
	margin: 0;  /* Centra la capa horitzontalment */
    background-color: #fff;
    overflow-y: scroll; 
    align-items: stretch;
    
    
}
.containers{
    position:fixed;
    box-sizing:border-box;
    top: 0; /* Posiciona la capa a la part superior de la pantalla */
    bottom:0;
    left:20%;
    width: 80%;
    padding:0;
    margin:0 auto;
}



#map {height:100vh;  width: 100%; }

.imatge-container {
    text-align: center;
    margin-bottom: 20px;
}

.imatge-font{
    margin:0;
    padding:0 12px;
    font-size:10px;
    box-sizing: border-box;
}

.imatge-container img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.no-imatge {
    width: 600px; /* Mateixa amplada que les imatges redimensionades */
    height: 200px; /* Alçada fixa per consistència */
    background-color: #f4f4f4;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    border-radius: 6px;
    color: #666;
    font-size: 16px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.dades-container {
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    margin: 24px 0;
}

.weather-widget{width:90%;display:flex;justify-content: center;}
.weather-widget > div{width:100%!important;}
.mm-widget__horizontal {
    max-width: none!important;
}

.dades-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top:10px;
}

.dada-box {
    background: #4384e5;
    color: #fff;
    border-radius: 18px;
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 0;
    min-height: 40px;
    box-shadow: 0 2px 10px rgba(10,35,90,0.08);
}

.dada-label {
    font-size: 0.85em;
    opacity: 0.7;
    margin-bottom: 6px;
    letter-spacing: 0.03em;
}

.dada-valor {
    font-size: 2em;
    font-weight: bold;
    line-height: 1.1;
}

.dada-web {
   background: #4384e5;
    color: #fff;
    border-radius: 18px;
    padding: 18px 12px;
    
    text-align: center;
    font-size: 1.1em;
    box-shadow: 0 2px 10px rgba(10,35,90,0.08);
    word-break: break-all;
}
.dada-web a {
    color: #fff;
    text-decoration: underline;
    font-size: 1.1em;
    word-break: break-all;
}

.opcions_tresor{
    display: flex;
    width: 92%;
    margin: 10px auto;
    justify-content: center;
    gap: 20px;
    box-sizing: border-box;
    padding:5px;
}
.opcions_tresor div {
    display: flex;
    justify-content:center;
    flex-direction: row;
    align-items: center;
    width: 50%;
    border:solid 1px grey;
    border-radius: 5px;
    box-sizing: border-box;
    gap:10px;
    color:#0c3864;
}

#imatges-instagram{
    top:10px;
    left:10px;
    z-index:25;
    position:absolute;
    background-color: orange;
    text-decoration: none;
    padding: 5px;
    border-radius: 5px;
    box-sizing: border-box;
    margin-left: 5%;
    box-shadow: 0 2px 10px rgba(0, 0, 1, 1);
    color:#444;
}

.visita-btn-container {
    width:94%;
    display: flex;
    gap: 10px;
    justify-content: space-between;
    margin: 20px auto;
}

.visita-btn, .projecte-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
}

.visita-btn img, .projecte-btn img {
    width: 24px;
    height: 24px;
}

.visitat {
    background-color: #28a745!important;
    color: white;
}

.projectat {
    background-color: #007bff!important;
    color: white;
}

.no-visitat, .no-projectat {
    background-color: #6c757d!important;
    color: white;
}

/* Botó visitat */
.visita-btn.visitat {
    background-color: #4caf50 !important; /* Verd */
    color: #fff !important;
    border: 2px solid #388e3c !important;
}
.visita-btn.no-visitat {
    background-color: #bbb !important; /* Gris fosc */
    color: #fff !important;
    border: 2px solid #888 !important;
}

/* Botó projectat */
.projecte-btn.projectat {
    background-color: #1976d2 !important; /* Blau */
    color: #fff !important;
    border: 2px solid #0d47a1 !important;
}
.projecte-btn.no-projectat {
    background-color: #bbb !important; /* Gris fosc */
    color: #fff !important;
    border: 2px solid #888 !important;
}

/* Estil general per als botons */
.visita-btn, .projecte-btn {
    border-radius: 50%;
    height: 48px;
    font-size: 1em;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0 8px;
    cursor: pointer;
    transition: background 0.2s, color 0.2s, border 0.2s;
    outline: none;
    border: 2px solid #bbb;
    background: #eee;
}

.visita-btn-container {
    text-align: center;
    margin-bottom: 20px;
}

#taulaMunicipis a{
	text-decoration:none;
	font-size:22px;
    color:black
}

.ordres{
    text-decoration: none;
    color: black;
    padding: 4px;
    
}
.estadistiques-container {
    padding: 15px;
    background-color: #f9f9f9;
    border-radius: 6px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.estadistiques-container h3 {
    color: #007BFF;
}

.estadistiques-container p {
    margin: 5px 0;
    font-size: 16px;
    color: #333;
	
	
	
}


.resum-estadistiques {
    position: fixed;
    bottom: 0;
    right: 0;
    width: 25%;
    background-color: rgba(255, 255, 255, 0.95);
    padding: 12px;
    text-align: right;
    border-top-left-radius: 12px;
    box-shadow: -2px -2px 6px rgba(0, 0, 0, 0.1);
    font-size: 15px;
    z-index: 99;
}

/*   Estils capsalera */
    header {
        position:fixed;
        height:50vh;
        overflow:hidden;
        width:20%;
        top:0;
        left:0;
        background: linear-gradient(45deg,rgb(133, 182, 238) 0%, #1a5fc7 100%);/*#bddbf5;*/
      /*border-bottom: 1px solid #ddd;*/
      padding: 0;
        margin: 0;
        z-index:999;
    }
    #header-index{
        height:125px;
    }

    .logo {
        display:flex;
        align-items: center;
      font-size: 1.8rem;
      font-weight: 600;
      color: #2c3e50;
      text-align:center;
      padding-top:0;
    }

    .tagline {
      font-size: 0.9rem;
      color: #7f8c8d;
    
    }

    
    .social {
      display: flex;
      justify-content:space-between;
      align-items: center;
      gap: 0.5rem;
      padding:10px;
      height:60px;

    }

    .social a {
        display: flex
        ;
            height: 60px;
            padding: 5px;
            align-items: center;
            text-align: center;
            box-sizing: border-box;

    }

    .social img {
      width: 24px;
      height: 24px;
    }

.nav-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    width: 100%;
    /*max-width: 600px;*/
    margin: 0 auto;
    position: absolute;
    bottom:0;
    gap:0;
}
#cap-info {
    width:96%;
    margin:4% auto;
    display: flex;
    flex-direction: row;
    justify-content:center;
    background-color: rgb(247, 82, 5);
    border: solid 1px grey;
    color:white;
    border-radius:5px;
    /* Afegim una ombra suau */
    box-shadow: 0 4px 16px rgba(0,0,1,1);
}
    

#cap-info img {
    width:35%;
    box-sizing: border-box;
}
#cap-info #desc_nivell {
    display:flex;
    flex-direction: column;
    justify-content: center;
    width:65%;
    box-sizing: border-box;
}


.nav-links a,.nav-links .menu-wrapper {
    /*flex: 0 0 35%;*/
    /*width:25%;*/
    box-sizing: border-box;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 8px;
}

.nav-links a img {
    width: 40px;
    height: 40px;
    object-fit: contain;
}



.menu-btn {
    padding: 8px;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
}

@media (max-width: 768px) {
   
    .nav-links {
        justify-content: space-between;
    }
    .municipi-container{
        overflow-y:scroll;
    }
    .resum-estadistiques {
        width: 100%;
        text-align: center;
        font-size: 14px;
        border-top-left-radius: 0;
        border-top-right-radius: 0;
    }
		
    .municipi-container, .tresor-container {
        width: 100%; /* Amplada completa per a pantalles petites */
        margin: 0; /* Elimina marges laterals */  
        height: calc(100svh - 130px);
        left:0;
    }
    
    h2{
        padding:8px 0px;
        text-align:justify;
        font-size:14px;
    }
    
    th, td {
        padding: 5px 5px 5px 12px; /* Redueix el padding */
        font-size: 12px;
    }
    
    .button-container a {
        padding: 8px 14px;
        font-size: 14px;
        margin: 5px;
    }
    .check-btn, .info-btn {
        font-size: 14px;
    }
}
.missatges-container {
    width:94%;
    margin:20px 3% 100px 3%;
    padding: 15px;
    border-top: 1px solid #ccc;
    box-sizing: border-box;
}

.missatge {
    border-bottom: 1px solid #eee;
    padding: 10px 0;
}

.missatge small {
    font-size: 0.8em;
    color: #666;
    margin-left: 10px;
}

.missatge-controls {
    margin-top: 5px;
}

.missatge-controls button {
    background-color: #f0f0f0;
    border: none;
    padding: 5px 10px;
    margin-right: 5px;
    cursor: pointer;
}

.missatge-controls button:hover {
    background-color: #ddd;
}

.nou-missatge {
    margin-top: 20px;
}

.nou-missatge textarea {
    width: 97%;
    padding: 10px;
}

#peu_taula{
    display:flex;
    justify-content:center;
    gap:10px;
    margin:10px 0;
    box-sizing: border-box;
}

.nou-missatge button {
    margin-top: 10px;
    padding: 8px 15px;
    background-color: #4CAF50;
    color: white;
    border: none;
    cursor: pointer;
}

#peu_taula a{
    display: inline-block;
    padding: 8px 14px;
    background: linear-gradient(180deg,#ffffff 0%, #e6e6e6 100%);
    color: #222;
    text-decoration: none;
    border: 1px solid #bbb;
    border-radius: 6px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.12);
    transition: background 0.15s ease, transform 0.08s ease, box-shadow 0.15s ease;
    font-size: 14px;
}

#peu_taula a:hover, #peu_taula a:focus{
    background: #f0f0f0;
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(0,0,0,0.14);
}

#peu_taula a:active{
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(0,0,0,0.12);
}

.nou-missatge button:hover {
    background-color: #45a049;
}
	

.municipi-container button{
   /* background-color: #eee!important;*/
   width:40%;
   border:solid 1px #bbb;
   background-color:#dae3eb!important;
   border-radius:5px;
   padding:5px;
   margin:5%;
  }
	
#enviarMissatgeBtn{
   /* background-color: #eee!important;*/
   width:auto;
   border:solid 1px #bbb;
   background-color:#777777!important;
}


	
.search-container {
    margin: 1em 0;
    width: 100%;
}

.search-row {
    display: flex;
    flex-direction: row;
    width: 98%;
    gap: 10px; /* Espai entre l'input i el botó */
    margin:1%
}

#filtreMunicipis {
    flex: 1; /* Permet créixer i adaptar-se a l'espai disponible */
    padding: 10px;
    font-size: 1em;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-sizing: border-box;
}

#locationBtn {
    padding: 10px 20px; /* Més espai horitzontal en escriptori */
    background-color: white;
    color: black;
    border: solid 1px grey;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1em;
    white-space: nowrap;
    transition: background-color 0.3s ease;
    text-align: center;
    min-width: 100px; /* Amplada mínima en escriptori */
}

#locationBtn:hover {
    background-color: #ddd;
}

/* Ajustaments per a dispositius mòbils */

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
    /*background: linear-gradient(135deg,rgb(133, 182, 238) 0%, #1a5fc7 100%);/*#bddbf5;*/
    /*border-bottom: 1px solid #ddd;*/
    width: 100%; /* Assegura que ocupa el 100% de la capa mare */
    box-sizing: border-box; /* Inclou el padding dins de l'amplada */
    margin: 0; /* Elimina qualsevol marge extern */
    flex-wrap: wrap;
}

.logo-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.logo {
    font-size: 20px;
    font-weight: bold;
    color: #333;
}

.tagline {
    font-size: 14px;
    color: #fff;
    margin-top: 5px;
}

.nav-container {
    display: flex;
    align-items: center;
    gap: 15px;
}

.tanca-sessio-btn {
    background-color: #007BFF;
    color: white;
    padding: 8px 12px;
    border-radius: 4px;
    text-decoration: none;
    font-size: 14px;
}

.tanca-sessio-btn:hover {
    background-color: #0056b3;
}

.social a img {
    width: 24px;
    height: 24px;
    margin-left: 10px;
}
#peu {
    position: fixed;
    bottom: 0;
    width: 20%;
    background: linear-gradient(135deg,rgb(133, 182, 238) 0%, #1a5fc7 100%);/*#bddbf5;  /* El mateix blau que la capçalera */
    /* border-top: 1px solid #ddd;*/
    padding: 0;
    z-index: 1000;
    height:50vh;
}

/* Ajusta el menú emergent */


.menu-emergent.hidden {
    display: none; /* Amagat quan té la classe hidden */
}

.menu-emergent:not(.hidden) {
    display: block; /* Mostra el menú quan no té la classe hidden */
}

/* Estils per a l'avís de cookies */
.cookie-notice {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: #f8f9fa;
    padding: 15px;
    border-top: 1px solid #ccc;
    box-shadow: 0 -2px 5px rgba(0,0,0,0.1);
    text-align: center;
    z-index: 1000;
    font-size: 14px;
}

.cookie-notice p {
    margin: 0 0 10px;
    color: #333;
}

.cookie-notice button {
    background-color: #007BFF;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 5px;
    cursor: pointer;
    margin: 5px;
}

.cookie-notice button:hover {
    background-color: #0056b3;
}

.cookie-notice a {
    color: #007BFF;
    text-decoration: underline;
}
#notaDadesIA{
    background-color:#f9ffd0;
    font-size:10px;
    width:90%;
    margin:5%;
    box-sizing: border-box;
    border:solid 1px grey;
    padding:5px;
    border-radius: 5px;
}

@media (max-width: 768px) {

    .header-container {
       flex-wrap: nowrap;
    }
    header {
        height:70px;
        width:100%;
    }
    .containers { 
        top: 70px; 
        bottom:60px;
        left:0;
        width:100%;
		height:calc(100dvh - 130px)!important;
        overflow-y:scroll;
    }
    #map{height: calc(100vh - 120px);}
    #peu{
        bottom: 0;
        width: 100%;
        height:60px;
    }

    /*
    .search-row {
        gap: 5px; 
    }
    
    /*#filtreMunicipis {
        flex: 0 0 75%; 
    }*/
    
    #locationBtn {
        flex: 0 0 23%; /* Botó ocupa 20-25% en mòbil */
        padding: 10px 5px; /* Menys padding horitzontal */
        min-width: unset; /* Elimina l'amplada mínima en mòbil */
    }

    .cookie-notice {
        font-size: 12px;
        padding: 10px;
    }
    .nav-links {
        /*flex-wrap: nowrap   ;*/
        width: 90%;
        margin:0 5%;
        /*position:inherit;
        top:auto;98
    }
    .nav-links a {
        /*flex: 1 1 0%; /* Cada enllaç ocupa el mateix espai */
        /*min-width: 0; /* Centra el contingut de cada enllaç */
    }
    /*
    .menu-emergent{
        right:inherit;
        left:-140%;
    }*/
}

/* Estils per a la secció d'explicació */
#index-container{
    display: flex;
    position:fixed;
    width: 100%;
    justify-content: center;
    align-items: center;
    padding: 20px; /* Espai al voltant del contingut */
    box-sizing: border-box; /* Inclou el padding dins de l'amplada i alçada */
}
.intro-container {
    position:fixed;
    width: 80%;
    top:140px;
    padding: 20px;
    background-color: rgba(255, 255, 255, 0.95);
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    text-align: justify;
    height: calc(100vh - 260px);
    overflow-y:scroll;
}

.intro-container h1 {
    font-size: 2rem;
    color: #2c3e50;
}

.intro-container p {
    font-size: 1.1rem;
    line-height: 1.6;
    color: #555;
    margin-bottom: 20px;
}

.intro-container .button-container {
    display:flex;
    justify-content: space-between;
    align-items: center;
    flex-direction: row;
    margin-top: 20px;
}

@media (max-width: 768px) {
    
    .intro-container h1 {
        font-size: 1.5rem;
    }
    .intro-container p {
        font-size: 1rem;
    }
}

/* Estils per a l'avís PWA */
.pwa-prompt {
    display: none;
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background-color: #f8f9fa;
    border: 1px solid #ccc;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    max-width: 90%;
    text-align: center;
    z-index: 1000;
}

.pwa-prompt p {
    margin: 0 0 10px;
    font-size: 16px;
    color: #333;
}

.pwa-prompt button {
    background-color: #3388ff;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 5px;
    cursor: pointer;
    margin: 5px;
}

.pwa-prompt button:hover {
    background-color: #2566cc;
}

.pwa-prompt .close-btn {
    background-color: #ccc;
}

.pwa-prompt .close-btn:hover {
    background-color: #999;
}

@media (max-width: 768px) {
    .pwa-prompt {
        font-size: 14px;
        padding: 10px;
    }
    .login-container {
            width:100%;
            margin:50px 0;
    }
}
.slider-container {
    position: relative;
    max-width: 600px;
    margin: 0 auto;
    overflow: hidden;
}
.slider {
    display: flex;
    transition: transform 0.5s ease-in-out;
}
.slide {
    min-width: 100%;
    box-sizing: border-box;
    position: relative;
}
.slide img {
    width: 90%;
    height: auto;
    margin-left:5%;
    border-radius:10px;
    border:solid 2px rgb(0 54 82);
}
.slider-nav {
    position: absolute;
    top: 50%;
    left: 6%;
    width: 89%;
    display: flex;
    justify-content: space-between;
    transform: translateY(-50%);
}
.slider-nav button {
    background: rgba(0, 0, 0, 0.5);
    border: none;
    color: black;
    padding: 10px;
    cursor: pointer;
    opacity: 0.6;
    width:auto;
}
.imatge-controls {
    position: absolute;
    top: 10px;
    right: 30px;
    display: flex;
    gap: 10px;
}
.imatge-controls button {
    background: rgba(0, 0, 0, 0.7);
    color: white;
    border: none;
    padding: 5px 10px;
    cursor: pointer;
}
.no-imatge {
    text-align: center;
    padding: 20px;
    background: #f0f0f0;
}

.dialog-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.dialog-box {
    background: white;
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    width: 300px;
}

.dialog-box h3 a{
    text-decoration: none;
    color: #04a7f3;
    background: #D7D7D5;
    padding: 8px 30px;
    border-radius: 4px;
}

.dialog-buttons {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
}

.dialog-buttons button {
    border: none;
    padding: 10px;
    margin: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.dialog-buttons .visita-btn.active {
    background-color: #008000; /* Verd per visitat */
    color: white;
}

.dialog-buttons .projecte-btn.active {
    background-color: #0000FF; /* Blau per projectat */
    color: white;
}

.dialog-buttons button.cancel {
    background-color: #808080; /* Gris per cancel·lar */
    color: white;
}

.dialog-button.cancel {
    background: #6c757d;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.location-marker {
    font-size: 25px;
    text-align: center;
    line-height: 25px;
}
.mapa-container iframe{
    height:450px;
}

.location-marker:hover {
    transform: scale(1.2);
    transition: transform 0.2s;
}

.mapa-btn, .menu-btn, .llista-btn {
    font-size: 24px;
    padding: 5px 10px;
    cursor: pointer;
}

.mapa-btn {
    background: none;
    border: none;
    padding: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mapa-btn img, .llista-btn img, .torna-btn img, .visita-btn img , .ordres img, #locationBtn img {
    width: 24px; /* Ajusta la mida de la icona */
    height: 24px; /* Ajusta la mida de la icona */
    object-fit: contain; /* Assegura que la imatge manté les proporcions */
    background: transparent; /* Fons transparent */
    
}

.menu-container {
    position: relative;
    display: inline-block;
}

.menu-btn {
    font-size: 24px;
    padding: 5px 10px;
    cursor: pointer;
}

.menu-emergent {
    position: absolute;
    bottom: 100%; /* Fa que el menú s'obri cap amunt */
    background-color: #eee;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    padding: 8px 0;
    min-width: 200px;
    z-index: 100; /* Assegura que el menú està per sobre del peu */
    display: none; /* Amagat per defecte */
    bottom: 25vh;
}

.menu-emergent.hidden {
    display: none; /* Amagat quan té la classe hidden */
}

.menu-emergent:not(.hidden) {
    display: block; /* Mostra el menú quan no té la classe hidden */
}

.menu-item {
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: background-color 0.2s;
}

.menu-item:hover {
    background-color: #f0f0f0;
}

.menu-icon {
    margin-right: 8px;
    font-size: 18px;
}

.menu-wrapper {
    position: relative;
    display: inline-block;
}

.menu-btn {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    padding: 8px;
}

.municipi-info {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    margin: 20px 0;
    flex-direction:column;
}

.escut-container {
    text-align: center;
    margin-bottom: 20px;
}

.escut-container img.escut {
    width: 80%;
    height: auto;
}

.dades-container {
    width:90%;
    margin: 0 auto;
    flex: 2;
    
}

.dades-container ul {
    list-style: none;
    padding: 0;
}

.dades-container ul li {
    margin-bottom: 10px;
}

/* Vista vertical (mòbils) */
@media (max-width: 768px) {
    .menu{
         right: 0;
    }
    .municipi-info {
        flex-direction: column;
        text-align: center;
    }

    .dades-container {
        padding-left: 0;
        margin:0 5%;
        width: 90%;
        text-align:justify;
        font-size:12px;
    }
    .info{text-align:center;}
        .mapa-container iframe{
        height:250px;
    }

}

#estadistiques {
    position: fixed;
    bottom: 70px; /* Ajusta segons l'alçada del teu peu */
    right: 10px;
    font-size: 0.85em;
    background-color: rgba(255, 255, 255, 0.9);
    padding: 5px 10px;
    border-radius: 4px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
    z-index: 1000;
    border:solid 1px grey;
    box-sizing: border-box;
}

.scanner-button {
    background-color: #4CAF50;
    color: white;
    padding: 15px 30px;
    border: none;
    border-radius: 10px;
    font-size: 1.2em;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
    margin: 10px auto;
    display: block;
}

.scanner-button:hover {
    background-color: #45a049;
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.3);
}

.classificacio_mes{
    width:92%;
    margin:4%;
    border-radius:10px;
    background-color: rgb(210, 250, 255);
    box-shadow: 0 6px 12px rgba(0,0,0,0.3);
}

.classificacio_mes th {
    background-color: rgb(65, 128, 247);
    color:white;
}
@media (max-width: 768px) {
    .menu-emergent {
        right: 0; 
        bottom:100px;
    }
}


/* central de Missatges */

.msg_option{

            color:#088;
            padding:8px;
            text-align:center;
            cursor:pointer;
            font-weight:bold;
            font-family: 'Nunito', 'Comic Sans MS', Arial, sans-serif;
            background-color:#c0ffaf;
            box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
            border-radius:5px;
            
        }
        .msg_selector{
            position:absolute;
            left:50%;
            top:50%;
            transform:translate(-50%,-50%);
            background:#fff8b3;
            border:1px solid #e6c84d;
            padding:8px;
            border-radius:8px;
            box-shadow:0 6px 18px rgba(0,0,0,0.18);
            z-index:9999;
            min-width:180px;
            max-width:320px;
            font-family:Arial,Helvetica,sans-serif;

        }
        #titol_msg{ 
            text-align:center;
            font-weight:700;
            margin-bottom:8px;
            color:#5a3f00;
        }
        #quadre_opcions{
            display:flex;
            flex-direction:column;
            gap:8px;
        }
        .msg_noenviar{
            padding:8px;
            cursor:pointer;
            color:#F00;
            text-align:center;
        }