﻿/* =====================================================
    Conecta.Tour — Folha de Estilos Principal
   ===================================================== */

/*=====================================*/   
/* Organizado por seção:
/* 1. Tokens de design
/* 2. Reset e Base
/* 3. Modo Escuro
/* 4. Navegação
/* 5. Dropdown de cidades
/* 6. Seção cidade
/* 7. Barra de info da cidade
/* 8. Bloco intro
/* 9. Info cards
/* 10. Scroll Track
/* 11. Agenda de eventos
/* 12. Seção de eventos
/* 13. Mapa interativo
/* 14. Informações úteis
/* 15. Seção transporte
/* 16. Utilitários
/* 17. Footer
/* 18. Animações
/* 19. Responsivo - Celular (<768px)
/*=====================================*/ 



/* =====================================================
    1. TOKENS DE DESIGN (variáveis CSS)
   ===================================================== */
:root {
    --c1: #0057FF;
    --c2: #FFD400;
    --c3: #0B3D91;
    --dark:   #0D1117;
    --gray-1: #2D3748;
    --gray-2: #5A6478;
    --gray-3: #9AA3B2;
    --gray-4: #EEF0F4;
    --bg:      #F4F3F1;
    --surface: #FFFFFF;
    --radius:    20px;
    --radius-lg: 28px;
    --shadow-sm: 0 1px 3px rgba(0,0,0,.06), 0 1px 2px rgba(0,0,0,.04);
    --shadow-md: 0 4px 6px rgba(0,0,0,.05), 0 10px 20px rgba(0,0,0,.08);
    --shadow-lg: 0 20px 45px rgba(0,0,0,.12), 0 4px 10px rgba(0,0,0,.06);

    /* Aliases usados na seção de Informações Úteis (faltavam) */
    --text: var(--dark);
    --text-light: var(--gray-2);
    --card-bg: var(--surface);
    --border: var(--gray-4);
}


/* =====================================================
    2. RESET & BASE
   ===================================================== */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: 'Inter', sans-serif;
    background: var(--bg);
    color: var(--dark);
    overflow-x: hidden;
    transition: background .3s ease, color .3s ease;
}


/* =====================================================
    3. MODO ESCURO
   ===================================================== */

/* Tokens sobrescritos no modo escuro */
body.dark-mode {
    --dark:   #F0F4FF;
    --gray-1: #C8D0E0;
    --gray-2: #8A96AB;
    --gray-3: #5A6478;
    --gray-4: #1E2535;
    --bg:      #0D1117;
    --surface: #161C2D;
}

/* Componentes no modo escuro */
body.dark-mode nav                  { background: rgba(13,17,23,.92); box-shadow: 0 1px 0 rgba(255,255,255,.06); }
body.dark-mode .nav-links           { background: #1E2535; }
body.dark-mode .nav-icon-btn        { background: #1E2535; color: var(--gray-1); border-color: #2D3748; }
body.dark-mode .agenda-filter       { background: #161C2D; border-color: #2D3748; }
body.dark-mode .agenda-date-input         { background: #1E2535; color: var(--dark); border-color: #2D3748; }
body.dark-mode .weather-card        { background: #161C2D; border-color: #2D3748; }
body.dark-mode .mapa-interativo-wrap{ background: #161C2D; border-color: #2D3748; }

/* Dropdown no modo escuro */
body.dark-mode .city-dropdown-menu              { background: #161b22; border: 1px solid #2d3748; }
body.dark-mode .city-dropdown-menu a            { color: #ffffff; }
body.dark-mode .city-dropdown-menu a:hover      { background: #222c40; }
body.dark-mode .city-dropdown-menu a.nav-active { background: rgba(0,87,255,.20); color: #6ea8ff; }

/* ---------------------------------------------------
   Ajustes extras de modo escuro
   (cobrem elementos que usam cor fixa no <style> do index.html
   e por isso não respeitavam o tema escuro)
   --------------------------------------------------- */
body.dark-mode                 { background-color: var(--bg) !important; color: var(--dark) !important; }
body.dark-mode .card1          { background-color: var(--surface) !important; border-color: #2D3748 !important; }
body.dark-mode .card1-titulo   { color: var(--dark) !important; }
body.dark-mode .card1-descricao{ color: var(--gray-2) !important; }
body.dark-mode .card1-status   { color: var(--gray-2) !important; border-top-color: #2D3748 !important; }
/* Texto secundário dentro do status (ex: "Fecha às 18h00" / "Abre hoje às..."), que vinha com cor fixa quase preta */
body.dark-mode .card1-status span[style*="0000008b"] { color: var(--gray-2) !important; }
/* Borda do card "Abrir Mapa Interativo", que ficava cinza-clara/branca sobre fundo escuro */
body.dark-mode .map-card-wrap { border-color: #2D3748 !important; }
body.dark-mode .carrossel1     { color: var(--dark) !important; }
body.dark-mode .card-1         { background-color: var(--surface) !important; border-color: #2D3748 !important; }
body.dark-mode #card-map,
body.dark-mode .card-map-abrir { box-shadow: 0 4px 14px rgba(0,0,0,.45); }
body.dark-mode .map-legend span:not(.legend-dot) { color: var(--dark); }


/* =====================================================
    4. NAVEGAÇÃO
   ===================================================== */
nav {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: 64px;
    background: rgba(255,255,255,.92);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 6%;
    z-index: 1000;
    box-shadow: 0 1px 0 rgba(0,0,0,.06);
    transition: background .3s ease;
}

/* Logo */
.logo {
    height: 40px;
    width: auto;
    object-fit: contain;
}

.nav-brand {
    font-size: 1.05rem;
    font-weight: 800;
    text-decoration: none;
    color: var(--dark);
    letter-spacing: -.3px;
}
.nav-brand .dot { color: var(--c1); }

/* Links centrais em pill */
.nav-links {
    display: flex;
    gap: 4px;
    background: var(--gray-4);
    padding: 4px;
    border-radius: 40px;
}
.nav-links a {
    padding: 6px 18px;
    text-decoration: none;
    color: var(--gray-2);
    font-size: .75rem;
    font-weight: 600;
    border-radius: 30px;
    transition: all .2s ease;
}
.nav-links a:hover,
.nav-links a.nav-active {
    background: var(--surface);
    color: var(--dark);
    box-shadow: var(--shadow-sm);
}

/* Ações à direita */
.nav-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}
.nav-icon-btn {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 1px solid var(--gray-4);
    background: var(--surface);
    color: var(--gray-2);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all .2s ease;
    flex-shrink: 0;
}
.nav-icon-btn:hover { background: var(--c1); color: #fff; border-color: var(--c1); transform: scale(1.08); }
.nav-icon-btn i { width: 16px; height: 16px; }


/* =====================================================
    5. DROPDOWN DE CIDADES
   ===================================================== */
.city-dropdown { position: relative; }

.city-dropdown-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    border: 1px solid var(--gray-4);
    background: var(--surface);
    padding: 10px 14px;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 600;
    color: var(--gray-2);
    transition: all .2s ease;
}
.city-dropdown-btn:hover,
.city-dropdown-btn.active {
    background: var(--c1);
    color: #fff;
    border-color: var(--c1);
    transform: scale(1.05);
}

.city-dropdown-menu {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    min-width: 220px;
    background: white;
    border-radius: 16px;
    padding: 8px;
    box-shadow: var(--shadow-lg);
    display: none;
    z-index: 9999;
}
.city-dropdown-menu.show { display: flex; flex-direction: column; }

.city-dropdown-menu a {
    text-decoration: none;
    color: var(--dark);
    padding: 12px 14px;
    border-radius: 10px;
    transition: .2s;
}
.city-dropdown-menu a:hover      { background: #f4f7ff; }
.city-dropdown-menu a.nav-active  { background: #e8f1ff; color: var(--c1); font-weight: 700; }


/* =====================================================
    6. SEÇÃO CIDADE — Hero card
   ===================================================== */
.city-section {
    padding: 60px 0px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    max-width: 1200px;
    margin: 0 auto;
}

/* Card principal com foto de fundo */
.img-cidade {
    width: 100%;
    height: 300px;
    background-size: cover;
    background-position: center;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: var(--shadow-lg);
    transition: transform .28s ease, box-shadow .28s ease;
}

/* Overlay escuro */
.img-cidade::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(105deg, rgba(0,0,0,.75) 0%, rgba(0,0,0,.18) 60%, transparent 100%);
}

/* Borda dourada no hover (aplicada via JS adicionando classe) */
.img-cidade::before {
    content: '';
    position: absolute;
    inset: 0;
    padding: 2px;
    border-radius: inherit;
    background: linear-gradient(135deg, rgba(255,246,194,.95) 0%, rgba(255,226,86,.9) 28%, rgba(255,212,0,.2) 62%, rgba(255,189,0,.9) 100%);
    opacity: 0;
    transition: opacity .28s ease;
    pointer-events: none;
    z-index: 1;
    -webkit-mask-composite: xor;
    mask-composite: exclude;
}
.city-info-main {  margin: 0 0 0 20px; z-index: 2; display: flex; flex-direction: column; color: #fff;}

/* Badges de destaque da cidade */
.city-badges {
    position: relative;
    z-index: 2;
    display: flex;
    gap: 10px;
}
.badge {
    background: rgba(255,255,255,.15);
    backdrop-filter: blur(12px);
    padding: 8px 16px;
    border-radius: 40px;
    color: #fff;
    font-size: .72rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
    border: 1px solid rgba(255,255,255,.25);
    letter-spacing: .3px;
}

/* =====================================================
    7. MENU CENTRAL
   ===================================================== */
.menu-central { display: flex; flex-wrap: nowrap; gap: 10px; width: 100%; height: auto; overflow-x: auto; padding: 0px 15px 10px; scroll-snap-type: x mandatory;  scrollbar-width: none; margin: -40px 0 0 0; }
.menu-central::-webkit-scrollbar { display: none; }
.menu-central::-webkit-scrollbar-thumb { background: var(--dark); border-radius: 10px; }
.menu-central-btn { height:65px; width:65px; color:var(--dark); background:var(--surface); padding:5px 5px; border-radius:12px; opacity:0; animation:surgirCard .6s ease forwards; transition:all .25s cubic-bezier(.4,0,.2,1); cursor:pointer; box-shadow:var(--shadow-sm); display:flex; flex-direction:column; align-items:center; justify-content:center; gap:5px; font-size:.7rem; font-weight:500; scroll-snap-align:start; flex:0 0 auto; }
.menu-central-btn.active { background: var(--accent); color: #fff;  }
.menu-central-btn.active .icon-circle { color: #fff; }
.menu-central-btn:nth-child(1) { animation-delay: .1s; }
.menu-central-btn:nth-child(2) { animation-delay: .2s; }
.menu-central-btn:nth-child(3) { animation-delay: .3s; }
.menu-central-btn:nth-child(4) { animation-delay: .4s; }
.menu-central-btn:nth-child(5) { animation-delay: .5s; }
.icon-circle { width: 40px; height: 30px; border-radius: 14px; display: flex; align-items: center; justify-content: center; color: var(--accent); flex-shrink: 0; }

@media (min-width: 768px) {
    .menu-central { justify-content: center; }
    .menu-central-btn { height: 80px; width: 80px; font-size: .8rem; }
}


/* =====================================================
    8. CARDS DINAMICOS PROVENIENTES DO MENU CENTRAL
   ===================================================== */

/* =====================================================
    8. BLOCO DE INTRODUÇÃO DA CIDADE
   ===================================================== */
.intro {
    display: none;
    margin-top: -100px;
    margin-bottom: 15px;
    background: var(--surface);
    padding: 100px 20px 15px 20px;
    border-radius: var(--radius-lg);
    line-height: 1.8;
    box-shadow: var(--shadow-md);
    width: 100%;
}/*
.intro h2 {
    font-size: 1.9rem;
    font-weight: 800;
    margin-bottom: 14px;
    letter-spacing: -.5px;
}
.intro p { color: var(--gray-1); font-size: .95rem; }
*/
/*
.cidade-info-bar {
    display: none;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 16px;
    margin-top: 30px;
}

.cidade-info-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 18px;
    background: var(--surface);
    border-radius: 16px;
    box-shadow: 0 4px 12px rgba(0,0,0,.08);
    min-width: 0;
}
.cidade-info-item svg    { width: 24px; height: 24px; color: var(--c1); flex-shrink: 0; }
.cidade-info-item strong { display: block; font-size: .95rem; font-weight: 700; color: var(--dark); }
.cidade-info-item span   { display: block; font-size: .75rem; color: var(--gray-2); }
*/
/* =====================================================
    10. SCROLL TRACK (sub-cards arrastáveis)
   ===================================================== */
.details-container {
    width: 100%;
    display: none;
    opacity: 0;
    transition: opacity .4s ease;
}
.details-container.show { display: block; opacity: 1; }

.scroll-track {
    display: flex;
    gap: 16px;
    padding: 12px 0 16px;
    overflow-x: auto;
    cursor: grab;
    scrollbar-width: none;
    -ms-overflow-style: none;
    user-select: none;
}
.scroll-track:active            { cursor: grabbing; }
.scroll-track::-webkit-scrollbar{ display: none; }

.sub-card {
    min-width: 270px;
    height: 180px;
    background-size: cover;
    background-position: center;
    border-radius: 22px;
    opacity: 0;
    animation: surgirCard .6s ease forwards;
    padding: 24px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    box-shadow: var(--shadow-md);
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
    pointer-events: none;
}
.sub-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,.85) 0%, rgba(0,0,0,.15) 55%, transparent 100%);
    z-index: 1;
}
.sub-card h6 { font-size: 1rem; font-weight: 700; color: #fff; z-index: 2; position: relative; line-height: 1.3; }
.sub-card p  { font-size: .75rem; color: rgba(255,255,255,.75); z-index: 2; position: relative; margin-top: 3px; }

/* =====================================================
    11. ESPAÇO PARA CARDS
   ===================================================== */
.details-container { background-color: rgba(184, 184, 184, 0.089);}
.details-grid { padding: 0px 10px; display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px;
}
@media (min-width: 768px) {
    .details-container { width: 100vw; background-color: rgba(184, 184, 184, 0.089); margin-top:-80px;}
    .details-grid { padding: 70px 200px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px;}

}

/* =====================================================
    11. CARDS
   ===================================================== */
.card-1 { border-radius: 12px; overflow: hidden; opacity: 0; animation: surgirCard .6s ease forwards; transition: transform .3s cubic-bezier(.4,0,.2,1), box-shadow .3s ease; display: flex; flex-direction: column; border: 1px solid rgba(0, 0, 0, 0.123); background-color: white;}
.card-1:hover { transform: translateY(-6px); box-shadow: 0 16px 36px rgba(0, 0, 0, 0.15); }
.card-1-banner { position: relative; height: 100px; overflow: hidden; }
.card-1-banner img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .45s ease; }
.card-1:hover .card-1-banner img { transform: scale(1.06); }
.card-1-banner .banner-fallback { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; } 
.card-1-banner .banner-fallback i { width: 48px; height: 48px; color: rgba(255,255,255,.6); }
.card-1-date-full { display: flex;align-items: center;gap: 6px;font-size: .72rem;font-weight: 700;color: var(--c1);letter-spacing: .2px;margin-bottom: 10px;text-transform: capitalize; }
.card-1-date-full i { width: 13px; height: 13px; flex-shrink: 0; }
.card-1-body { padding: 10px 15px 15px 15px; flex: 1; display: flex; flex-direction: column; }
.card-1-body h3 { font-size: 13px; font-weight: 800; margin-bottom: 8px; color: var(--dark); line-height: 1.35; letter-spacing: -.3px; }
.card-1-body .desc { font-size: .8rem; color: var(--gray-2); flex: 1; }
.card-1-btn { margin-top: 10px; border: none; border-radius: 12px; padding: 8px 0; background: orange; color: #fff; text-align: center; cursor: pointer; display: flex; flex-direction: row; align-items: center; justify-content: center; gap: 4px; font-size: .85rem; font-weight: 500; }

/* =====================================================
    11. HERANÇAS DA AGENDA
   ===================================================== */
.agenda-section {
    max-width: 1200px;
    margin: 0 auto;
}

/* Cabeçalho */
.agenda-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    margin-bottom: 36px;
    flex-wrap: wrap;
    gap: 16px;
}
.agenda-header h2 { font-size: 2.4rem; font-weight: 800; letter-spacing: -3px; line-height: 1.1; }
.agenda-header h2 span { color: var(--c1); }
.agenda-header p { color: var(--gray-2); font-size: .85rem; margin-top: 8px; }

/* Filtros em pill */
.agenda-filter {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
    background: var(--surface);
    padding: 5px;
    border-radius: 40px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--gray-4);
}
.filter-btn {
    border: none;
    background: transparent;
    border-radius: 30px;
    padding: 7px 18px;
    font-size: .73rem;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s ease;
    color: var(--gray-2);
    font-family: inherit;
}
.filter-btn:hover  { color: var(--dark); background: var(--gray-4); }
.filter-btn.active { background: var(--c1); color: #fff; box-shadow: 0 2px 10px rgba(0,87,255,.35); }

/* Grid de cards */
.agenda-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    padding: 0 20px 10px;
}



/* Badge de categoria */
.agenda-cat-badge {
    position: absolute;
    top: 14px; left: 14px;
    background: rgba(255,255,255,.95);
    backdrop-filter: blur(8px);
    border-radius: 20px;
    padding: 5px 12px;
    font-size: .65rem;
    font-weight: 700;
    letter-spacing: .8px;
    text-transform: uppercase;
    box-shadow: 0 2px 8px rgba(0,0,0,.12);
    color: var(--c1); /* fallback caso o evento não traga "cor" no JSON */
}

/* Bloco de data */
.agenda-date-block {
    position: absolute;
    top: 14px; right: 14px;
    background: #fff;
    border-radius: 16px;
    padding: 8px 12px;
    text-align: center;
    box-shadow: 0 4px 14px rgba(0,0,0,.18);
    min-width: 54px;
}
/* Cores FIXAS — o fundo do bloco de data é sempre branco,
   então o texto não pode depender de variáveis que mudam no dark mode */
.agenda-date-block .day   { font-size: 1.45rem; font-weight: 800; line-height: 1; color: #0B3D91; }
.agenda-date-block .month { font-size: .58rem; font-weight: 700; text-transform: uppercase; color: #5A6478; letter-spacing: 1.2px; margin-top: 2px; }


.agenda-meta      { display: flex; flex-direction: column; gap: 8px; border-top: 1px solid var(--gray-4); padding-top: 14px; }
.agenda-meta-item { display: flex; align-items: center; gap: 8px; font-size: .9rem; color: var(--gray-1); }
.agenda-meta-item i    { width: 14px; height: 14px; flex-shrink: 0; }
.agenda-meta-item span { font-weight: 600; }

/* Estado vazio */
.agenda-empty { text-align: center; padding: 70px 20px; color: var(--gray-3); font-size: .9rem; grid-column: 1 / -1; }

/* Botão de mais informações */
.agenda-actions { margin-top: 18px; }
.btn-mais-info {
    display: flex;
    gap:10px;
    align-items: center;
    justify-content: center;
    padding: 8px 16px;
    background: var(--c1);
    color: #fff;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 500;
    transition: .25s;
}
.btn-mais-info:hover { opacity: .9; transform: translateY(-2px); }

.agenda-local-link {
    color: inherit;
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
    cursor: pointer;
    transition: opacity .2s ease;
}

.agenda-local-link:hover {
    opacity: .75;
}

/* =====================================================
    12. SEÇÕES DE EVENTOS (legado / outros formatos)
   ===================================================== */
.events-section-2,
.events-section {
    padding: 60px 5%;
    max-width: 1200px;
    margin: 0 auto;
}

/* Títulos */
.events-title-2 { text-align: center; margin-bottom: 40px; }
.events-title   { margin-bottom: 40px; }

.events-title-2 h2,
.events-title h2   { font-size: 2.2rem; font-weight: 800; margin-bottom: 10px; letter-spacing: -.5px; }

.events-title-2 p,
.events-title p    { color: var(--gray-2); }

/* Grids */
.events-grid-2,
.events-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 22px;
}

/* Cards */
.event-card-2,
.event-card {
    background: var(--surface);
    border-radius: 24px;
    overflow: hidden;
    opacity: 0;
    animation: surgirCard .6s ease forwards;
    box-shadow: var(--shadow-md);
    transition: transform .3s ease, box-shadow .3s ease;
    border: 1px solid rgba(0,0,0,.04);
}
.event-card-2:hover,
.event-card:hover  { transform: translateY(-6px); border: 1px solid var(--c1); box-shadow: 0 16px 36px rgba(0,87,255,.15); }

.event-card-2 img,
.event-card img    { width: 100%; opacity: 0; animation: surgirCard .6s ease forwards; height: 220px; object-fit: cover; }

.event-content-2,
.event-content     { padding: 24px; }

.event-date-2,
.event-date        { font-size: .7rem; font-weight: 700; color: var(--c1); letter-spacing: 1px; text-transform: uppercase; }

.event-content-2 h3,
.event-content h3  { margin: 12px 0 8px; font-size: 1.2rem; font-weight: 800; letter-spacing: -.3px; }

.event-content-2 p,
.event-content p   { color: var(--gray-2); line-height: 1.6; font-size: .88rem; }


/* =====================================================
    13. MAPA INTERATIVO
   ===================================================== */
.mapa-interativo-section { padding-top: 0; }

/* Legenda de filtros do mapa */
.map-legend {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
}
.legend-item {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: .75rem;
    font-weight: 600;
    color: var(--gray-2);
    cursor: pointer;
    padding: 6px 14px;
    border-radius: 20px;
    border: 1px solid var(--gray-4);
    background: var(--surface);
    transition: all .2s ease;
    user-select: none;
}
.legend-item:hover  { color: var(--dark); box-shadow: var(--shadow-sm); }
.legend-item.inactive { opacity: 0.4; }

.legend-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }

/* Container do mapa */
.mapa-interativo-wrap {
    background: var(--surface);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--gray-4);
    height: 520px;
    position: relative;
    transition: background .3s ease, border-color .3s ease;
}

/* Placeholder enquanto o mapa carrega */
.mapa-placeholder { display: flex; flex-direction: column; align-items: center; justify-content: center; height: 100%; gap: 12px; color: var(--gray-3); }
.mapa-placeholder i { width: 40px; height: 40px; }

/* iFrame do mapa */
.mapa-interativo-wrap iframe { width: 100%; height: 100%; border: none; display: block; }

/* Popup customizado */
.map-popup {
    position: absolute;
    background: var(--surface);
    border-radius: 16px;
    padding: 16px 20px;
    box-shadow: var(--shadow-lg);
    min-width: 200px;
    z-index: 10;
    pointer-events: none;
    opacity: 0;
    transform: translateY(8px);
    transition: all .25s ease;
    border: 1px solid var(--gray-4);
}
.map-popup.show { opacity: 1; transform: translateY(0); pointer-events: auto; }
.map-popup h4   { font-size: .9rem; font-weight: 800; margin-bottom: 4px; color: var(--dark); }
.map-popup p    { font-size: .75rem; color: var(--gray-2); line-height: 1.5; }

.map-popup-badge {
    display: inline-block;
    font-size: .6rem;
    font-weight: 700;
    letter-spacing: .8px;
    text-transform: uppercase;
    padding: 3px 8px;
    border-radius: 20px;
    margin-bottom: 8px;
}

/* Marcador SVG personalizado */
.map-marker { cursor: pointer; transition: transform .2s ease; transform-origin: center bottom; }
.map-marker:hover { transform: scale(1.25); }

/* Estilos do Leaflet */
.leaflet-popup-content-wrapper { border-radius: 16px !important; box-shadow: 0 8px 30px rgba(0,0,0,.12) !important; padding: 0 !important; font-family: 'Inter', sans-serif !important; }
.leaflet-popup-content          { margin: 0 !important; padding: 16px 20px !important; }
.leaflet-popup-tip-container    { display: none; }
.leaflet-container              { font-family: 'Inter', sans-serif; }


/* =====================================================
    14. INFORMAÇÕES ÚTEIS
   ===================================================== */
.info-uteis-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    padding: 0 20px 20px;
}

.info-util-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 22px;
    box-shadow: var(--shadow-sm);
    transition: background .3s ease, border-color .3s ease;
}

.info-util-header { display: flex; align-items: center; gap: 18px; margin-bottom: 22px; }

.info-util-icon { width: 58px; height: 58px; border-radius: 18px; display: flex; justify-content: center; align-items: center; flex-shrink: 0; }
.info-util-icon svg { width: 26px; height: 26px; }

.info-util-title          { display: flex; flex-direction: column; }
.info-util-title h3       { margin: 0; font-size: 1.08rem; color: var(--text); font-weight: 700; }
.info-util-title span     { margin-top: 4px; font-size: .85rem; color: #8b8b95; }

.info-util-lista { display: flex; flex-direction: column; gap: 16px; }

.info-util-item { background: var(--card-bg); border: 1px solid var(--border); border-radius: 16px; padding: 18px; transition: .25s; }
.info-util-item:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(0,0,0,.08); border-color: var(--c1); }

.info-util-item-nome { font-size: 1rem; font-weight: 700; margin-bottom: 14px; color: var(--text); }

.info-util-item-detalhe { display: flex; align-items: flex-start; gap: 10px; margin-top: 10px; color: var(--text-light); font-size: .92rem; line-height: 1.5; }
.info-util-item-detalhe svg { width: 17px; height: 17px; margin-top: 2px; color: var(--c1); flex-shrink: 0; }


/* =====================================================
    15. MODAL DE DETALHES
   ===================================================== */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.55);
    backdrop-filter: blur(5px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    pointer-events: none;
    transition: opacity .3s ease;
}
.modal-overlay.show {
    opacity: 1;
    pointer-events: all;
}
.modal-card {
    background: var(--surface);
    border-radius: 24px;
    max-width: 480px;
    width: 100%;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    position: relative;
    max-height: 90vh;
    overflow-y: auto;
    transform: translateY(24px);
    transition: transform .3s cubic-bezier(.4,0,.2,1);
    scrollbar-width: none;
}
.modal-card::-webkit-scrollbar { display: none; }
.modal-overlay.show .modal-card { transform: translateY(0); }
.modal-close {
    position: absolute;
    top: 12px; right: 12px;
    z-index: 10;
    background: rgba(0,0,0,.45);
    border: none;
    border-radius: 50%;
    width: 36px; height: 36px;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer;
    color: #fff;
    backdrop-filter: blur(8px);
    transition: background .2s;
}
.modal-close:hover { background: rgba(0,0,0,.7); }
.modal-close i { width: 18px; height: 18px; }
.modal-banner img {
    width: 100%; height: 240px;
    object-fit: cover; display: block;
}
.modal-banner .banner-fallback {
    height: 240px;
    display: flex; align-items: center; justify-content: center;
}
.modal-body { padding: 24px; }
.modal-badge {
    display: inline-block;
    border-radius: 20px;
    padding: 5px 14px;
    font-size: .65rem;
    font-weight: 700;
    letter-spacing: .8px;
    text-transform: uppercase;
    margin-bottom: 14px;
}
.modal-body h2 {
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--dark);
    margin-bottom: 8px;
    line-height: 1.3;
}
.modal-desc {
    font-size: .88rem;
    color: var(--gray-2);
    line-height: 1.65;
    margin-bottom: 18px;
}
.modal-meta {
    display: flex;
    flex-direction: column;
    gap: 10px;
    border-top: 1px solid var(--gray-4);
    padding-top: 16px;
    margin-bottom: 20px;
}
.modal-meta-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: .85rem;
    color: var(--gray-1);
    line-height: 1.5;
}
.modal-meta-item i { width: 16px; height: 16px; flex-shrink: 0; margin-top: 2px; color: var(--c1); }
.modal-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.modal-btn {
    flex: 1;
    min-width: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 18px;
    border-radius: 14px;
    font-size: .85rem;
    font-weight: 700;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: .2s;
}
.modal-btn i { width: 16px; height: 16px; }
.modal-btn-maps { background: var(--c1); color: #fff; }
.modal-btn-maps:hover { background: #0045cc; }
.modal-btn-site { background: var(--gray-4); color: var(--dark); }
.modal-btn-site:hover { filter: brightness(.93); }


/* =====================================================
    16. SEÇÃO TRANSPORTE
   ===================================================== */
.transporte-section { padding-top: 30px; }

.transporte-section .agenda-grid {
    display: flex;
    justify-content: center;
    gap: 24px;
    flex-wrap: wrap;
}

.transporte-section .agenda-card {
    flex: 0 1 320px;
    max-width: 400px;
}

/* =====================================================
    16. UTILITÁRIOS
   ===================================================== */
.divider {
    width: 90%;
    height: 1px;
    background: linear-gradient(to right, transparent, var(--gray-4), transparent);
    border: none;
    margin: 20px auto;
}


/* =====================================================
    17. FOOTER
   ===================================================== */
footer {
    margin-top: 60px;
    padding: 32px 20px;
    background: var(--surface);
    border-top: 1px solid var(--gray-4);
    text-align: center;
}
.footer-content           { max-width: 1100px; margin: auto; }
.footer-content img       { width: 110px; margin-bottom: 14px; }
.footer-content p         { color: var(--gray-2); margin-bottom: 8px; }
.footer-content span      { color: var(--gray-3); font-size: .85rem; }

.footer-contact { margin: 18px 0 22px; }
.footer-contact-title { font-weight: 700; color: var(--dark); margin-bottom: 12px; }
.footer-contact-links { display: flex; justify-content: center; gap: 14px; flex-wrap: wrap; }
.footer-contact-link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    border-radius: 30px;
    border: 1px solid var(--gray-4);
    background: var(--bg);
    color: var(--dark);
    text-decoration: none;
    font-size: .85rem;
    font-weight: 600;
    transition: .2s;
}
.footer-contact-link:hover { background: var(--c1); color: #fff; border-color: var(--c1); }
.footer-contact-link i { width: 16px; height: 16px; }

.error-hero {
    background: linear-gradient(115deg, rgba(0,87,255,.95) 0%, rgba(11,61,145,.9) 45%, rgba(255,212,0,.72) 100%);
    min-height: 320px;
    border-radius: 32px;
    box-shadow: var(--shadow-lg);
}

.error-hero .city-info-main {
    max-width: 420px;
    margin-left: 42px;
}

.error-hero h2 {
    font-size: clamp(4rem, 10vw, 6.5rem);
    margin: 6px 0;
}

.error-hero h3 {
    font-size: clamp(2rem, 4vw, 2.6rem);
    color: rgba(255,255,255,.95);
}

.error-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 24px;
}

.error-card .card-1-btn {
    margin-top: auto;
    text-decoration: none;
}

.error-card .banner-fallback {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
}

.error-card .banner-fallback i {
    width: 36px;
    height: 36px;
}

@media (max-width: 768px) {
    .error-hero {
        min-height: 260px;
    }

    .error-hero .city-info-main {
        margin-left: 24px;
    }

    .error-actions {
        flex-direction: column;
        align-items: stretch;
    }
}

/* =====================================================
    18. ANIMAÇÕES
   ===================================================== */
@keyframes surgirCard {
    from { opacity: 0; transform: translateY(30px) scale(.96); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}


/* =====================================================
    19. RESPONSIVO — MOBILE (≤ 768px)
   ===================================================== */
@media (max-width: 768px) {
    .city-info-main { gap: 12px; width: 100%; }
    .card-num { font-size: clamp(2.4rem, 9vw, 4rem); flex-shrink: 0; }
}

/* Filtro por data */

.agenda-external-links {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 14px;
}
.agenda-external-links a {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: 20px;
    background: var(--surface);
    border: 1px solid var(--gray-4);
    color: var(--gray-1);
    text-decoration: none;
    font-size: .78rem;
    font-weight: 600;
    transition: .2s;
}
.agenda-external-links a:hover { background: var(--c1); color: #fff; border-color: var(--c1); }
.agenda-external-links a i { width: 14px; height: 14px; }

.agenda-date-filter{
    margin-bottom:30px;
    display:flex;
    flex-direction:column;
    gap:10px;
    max-width:260px;
}

.agenda-date-filter label{
    display:flex;
    align-items:center;
    gap:8px;
    font-size:.82rem;
    font-weight:700;
    color:var(--gray-1);
}

.agenda-date-filter label svg{
    width:18px;
    height:18px;
    color:var(--c1);
}

.agenda-date-input{
    width:100%;
    padding:12px 16px;
    border-radius:14px;
    border:1px solid var(--gray-4);
    background:var(--surface);
    color:var(--dark);
    font-family:inherit;
    font-size:.9rem;
    font-weight:600;
    box-shadow:var(--shadow-sm);
    transition:.25s;
    outline:none;
}

.agenda-date-input:hover{
    border-color:#b9cdfc;
}

.agenda-date-input:focus{
    border-color:var(--c1);
    box-shadow:0 0 0 4px rgba(0,87,255,.10);
}

.agenda-date-filter{
    margin-top:18px;
    max-width:260px;
    display:flex;
    flex-direction:column;
    gap:10px;
}

/* Paginação */

.agenda-pagination{
    margin-top:40px;
    display:flex;
    justify-content:center;
    align-items:center;
    gap:10px;
    flex-wrap:wrap;
}

.pagination-btn{
    border:none;
    background:var(--surface);
    color:var(--dark);
    border:1px solid var(--gray-4);
    min-width:42px;
    height:42px;
    padding:0 16px;
    border-radius:12px;
    cursor:pointer;
    font-family:inherit;
    font-weight:700;
    transition:.25s;
    box-shadow:var(--shadow-sm);
}

.pagination-btn:hover{
    background:var(--c1);
    color:#fff;
    border-color:var(--c1);
}

.pagination-btn.active{
    background:var(--c1);
    color:#fff;
    border-color:var(--c1);
}

.pagination-btn:disabled{
    opacity:.4;
    cursor:not-allowed;
}


/* ===== TABELA DE CORES ===== */

/* #FFFFFF - Branco */
/* #000000 - Preto */

/* #FF0000 - Vermelho */
/* #FFA500 - Laranja */
/* #FFFF00 - Amarelo */
/* #00FF00 - Verde */
/* #00FFFF - Ciano */
/* #0000FF - Azul */
/* #800080 - Roxo */
/* #FFC0CB - Rosa */
/* #A52A2A - Marrom */
/* #808080 - Cinza */

/* #FFD700 - Dourado */
/* #C0C0C0 - Prata */
/* #40E0D0 - Turquesa */
/* #4CAF50 - Verde Material */
/* #0057FF - Azul Royal */
/* #0B3D91 - Azul Marinho */

/* =====================================================
    21. BOTÃO "IR ATÉ LÁ" (rota no mapa interativo)
   ===================================================== */
.popup-rota-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    margin-top: 8px;
    padding: 6px 12px;
    background: var(--c1);
    color: #fff;
    border: none;
    border-radius: 20px;
    font-size: .72rem;
    font-weight: 700;
    cursor: pointer;
    transition: filter .2s ease;
    font-family: 'Inter', sans-serif;
}
.popup-rota-btn:hover { filter: brightness(1.1); }

/* Ajusta as cores do plugin de rotas (Leaflet Routing Machine) no modo escuro */
body.dark-mode .leaflet-routing-container {
    background: var(--surface) !important;
    color: var(--dark) !important;
}