/* Estilos globais */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;700&display=swap');
body {
    font-family: "Montserrat", sans-serif;
    font-optical-sizing: auto;
    font-style: normal;
    margin: 0;
    padding: 0;
    background-color: #F2F0F0;
    display: flex;
    flex-direction: column;
}

html, body {
    height: 100%;
    margin: 0;
}
main {
    flex: 1; /* Faz o conteúdo ocupar o espaço restante */
}


body, input, button, select, textarea{
    font-family: "Montserrat", sans-serif;
}

.header, .banner, .menu, .footer {
    width: 100%;
}

/* Garanta que os ícones usem a fonte do Font Awesome */
.fa-solid, .fas {
  font-family: "Font Awesome 6 Free" !important;
  font-weight: 900 !important; /* necessário para o estilo solid (free) */
}

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

/* Header */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
    background-color: #DEF0FE;
}

.header-left img {
    height: 25px;
}

.header-center {
    flex-grow: 1;
    text-align: center;
    /* Adicionando um max-width para não ocupar todo o espaço */
    max-width: 500px;
}

.search-bar {
    width: 100%; /* Ajuste para preencher o container */
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.search-container {
    display: flex;
    align-items: center;
    gap: 8px; /* espaço entre input e ícone */
    border: 1px solid #ccc;
    border-radius: 4px;
    padding: 0 8px;
    background: #fff;
}

.search-bar {
    flex: 1; /* ocupa o espaço restante */
    border: none;
    outline: none;
    padding: 8px 4px;
    font-size: 14px;
}

.search-container i {
    color: #666;
    cursor: pointer;
}

.login-button {
    padding: 8px 16px;
    background-color: #397AAB;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    white-space: nowrap; /* Impede que o texto "Entrar" quebre */
    margin-left: 10px; /* Adiciona uma pequena margem para separar */
}

/* Banner */
.banner {
    width: 100%;
}

.banner-image {
  width: 100%;
  height: auto;
  display: block;         /* remove o gap da linha de base */
  /* opcional: */
  /* vertical-align: middle;  (alternativa) */
}

/* Menu */
.menu {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #397AAB;
    color: white;
    padding: 8px 16px;
}

.menu-left, .menu-right {
    display: flex;
    /* Garante que os itens do menu não encolham excessivamente */
    flex-shrink: 0; 
}

.menu-item {
    color: white;
    text-decoration: none;
    padding: 5px 15px;
    transition: background-color 0.3s;
    white-space: nowrap; /* Impede que o texto dos botões quebre */
}

.menu-item:hover, .menu-item.active {
    background-color: rgba(255, 255, 255, 0.2);
    border-bottom: 2px solid white;
}

/* ... (resto do CSS) ... */

/* Media Queries para telas menores (opcional, mas recomendado) */
@media (max-width: 768px) {
    .header {
        flex-wrap: wrap; /* Permite que os itens do cabeçalho quebrem em novas linhas */
        justify-content: center;
    }
    .header-center {
        order: 3; /* Move a barra de pesquisa para baixo */
        width: 100%;
        margin-top: 10px;
    }
    .header-left, .header-right {
        order: 1;
        width: 50%;
        text-align: center;
    }
    .header-right {
        text-align: right;
    }

    .menu {
        flex-wrap: wrap;
        justify-content: center;
        text-align: center;
    }
    .menu-left, .menu-right {
        flex-grow: 1;
        justify-content: center;
        margin: 5px 0;
    }
}

/* Index (Main Content) */
.main-content {
    padding: 20px;
}

.resource-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.map-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.map-item {
    background-color: #fff;
    border: 1px solid #ccc;
    border-radius: 8px;
    overflow: hidden;
    text-align: center;
    padding: 15px;
}

.map-preview {
    width: 100%;
    height: 150px;
    background-color: #e0e0e0; /* Placeholder para o mapa */
    margin-bottom: 10px;
}

.view-button {
    display: inline-block;
    padding: 8px 16px;
    background-color: #397AAB;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    margin-top: 10px;
}

/* Mapa Detail Page */
.map-detail-page {
    display: flex;
    gap: 20px;
    padding: 20px;
}

.map-container {
    flex: 2;
}

.map-frame {
    width: 100%;
    height: 600px;
    background-color: #e0e0e0;
    border: 1px solid #ccc;
}

.map-info-panel {
    flex: 1;
    background-color: #fff;
    border: 1px solid #ccc;
    border-radius: 8px;
    padding: 20px;
}

.info-header {
    border-bottom: 1px solid #ccc;
    padding-bottom: 10px;
    margin-bottom: 10px;
}

.info-tabs {
    display: flex;
    margin-bottom: 15px;
}

.info-tab-button {
    background: none;
    border: none;
    padding: 10px 15px;
    cursor: pointer;
    border-bottom: 2px solid transparent;
}

.info-tab-button.active {
    border-bottom: 2px solid #397AAB;
    font-weight: bold;
}

.info-content p {
    margin: 5px 0;
}

.footer {
    background-color: #FFFFFF;
    color: #333;
    text-align: center;
    padding: 1px;
    border-top: 1px solid #ccc;
}

/* Media Queries para telas menores (opcional, mas recomendado) */
@media (max-width: 768px) {
    .header {
        flex-wrap: wrap; /* Permite que os itens do cabeçalho quebrem em novas linhas */
        justify-content: center;
    }
    .header-center {
        order: 3; /* Move a barra de pesquisa para baixo */
        width: 100%;
        margin-top: 10px;
    }
    .header-left, .header-right {
        order: 1;
        width: 50%;
        text-align: center;
    }
    .header-right {
        text-align: right;
    }

    .menu {
        flex-wrap: wrap;
        justify-content: center;
        text-align: center;
    }
    .menu-left, .menu-right {
        flex-grow: 1;
        justify-content: center;
        margin: 5px 0;
    }
}
/* Novo CSS para a página mapa_geral */
.iframe-wrapper {
    /* Ocupa todo o espaço disponível entre o menu e o rodapé */
    height: calc(100vh - 180px); /* Ajuste este valor se necessário */
    width: 100%;
    overflow: hidden;
}

#mapa-geral-sig {
    width: 100%;
    height: 100%;
    border: none;
    display: block;
}