/* Reset e Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    color: #523827;
    /* Marrom profundo para texto */
    background-color: #fff3d8;
    /* Creme suave para fundo principal */
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header - Cor vinho/bordô */
.header {
    background: #8B4356;
    color: white;
    padding: 0.5rem 0;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo a {
    display: flex;
    align-items: center;
    text-decoration: none;
    transition: transform 0.3s ease;
}

.logo a:hover {
    transform: scale(1.05);
}

.logo-img {
    height: 60px;
    width: auto;
    margin: 0px;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 700;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 1rem;
}

.nav-link {
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    padding: 10px 16px;
    border-radius: 6px;
    position: relative;
    font-size: 0.95rem;
    letter-spacing: 0.5px;
}

.nav-link:hover {
    color: #ffe63d;
    background: rgba(255, 230, 61, 0.1);
    transform: translateY(-1px);
    text-shadow: 0 2px 4px rgba(255, 230, 61, 0.3);
}

.nav-link.active {
    color: #ffe63d !important;
    background: rgba(255, 230, 61, 0.2) !important;
    font-weight: 600 !important;
    border-radius: 4px;
    border-bottom: 2px solid #ffe63d;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: white;
    margin: 3px 0;
    transition: 0.3s;
}

/* SUBMENU */
.nav-item-with-submenu {
    position: relative;
}

.submenu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: #8B4356; /* Mesma cor vinho do header */
    min-width: 220px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
    z-index: 1001;
    list-style: none;
    padding: 8px 0;
    border-radius: 0 0 8px 8px;
    overflow: hidden;
    border-top: 2px solid #ffe63d;
}

.submenu li {
    padding: 0;
}

.submenu a {
    color: white;
    padding: 12px 20px;
    text-decoration: none;
    display: block;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    font-weight: 500;
    border-left: 3px solid transparent;
}

.submenu a:hover {
    background: rgba(255, 230, 61, 0.1);
    color: #ffe63d;
    border-left-color: #ffe63d;
    transform: translateX(3px);
}

.submenu a.active {
    background: rgba(255, 230, 61, 0.15);
    color: #ffe63d;
    border-left-color: #ffe63d;
    font-weight: 600;
}

.nav-item-with-submenu:hover .submenu {
    display: block;
}

/* Ajuste para o link principal quando há submenu */
.nav-item-with-submenu>.nav-link::after {
    content: ' ▼';
    font-size: 0.8em;
}

/* Banner */
.banner {
    height: 60vh;
    background: linear-gradient(135deg, #873b4b 0%, #4b6a88 100%);
    /* Gradiente de azul petróleo para azul acinzentado */
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    position: relative;
}

.banner-content {
    z-index: 2;
}

.banner-title {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.banner-subtitle {
    font-size: 1.2rem;
    font-weight: 300;
    max-width: 600px;
}

.banner-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
}

/* Hero Section Dinâmica */
.hero-section {
    position: relative;
    width: 100%;
    height: auto;
    /* Altura automática baseada na imagem */
    max-height: 70vh;
    /* Controla a altura máxima em monitores ultrawide */
    overflow: hidden;
}

.hero-content {
    position: relative;
    display: block;
    width: 100%;
}

.hero-image {
    width: 100%;
    height: auto;
    display: block;
    max-height: 70vh;
    /* Altura máxima para controlar em ultrawide */
    object-fit: cover;
    /* Preenche largura mantendo proporção */
    object-position: center;
    /* Centraliza o foco da imagem */
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1;
}

.hero-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: white;
    z-index: 2;
    max-width: 800px;
    padding: 0 2rem;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hero-subtitle {
    font-size: 1.3rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

/* Responsividade do Hero */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .hero-text {
        padding: 0 1rem;
        max-width: 90%;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }
}

/* Controle para diferentes resoluções */
@media (min-width: 1920px) {
    .hero-section {
        max-height: 60vh;
        /* Reduz altura em telas grandes */
    }

    .hero-image {
        max-height: 60vh;
    }
}

@media (min-width: 2560px) {
    .hero-section {
        max-height: 50vh;
        /* Ainda menor em monitores 2K+ */
    }

    .hero-image {
        max-height: 50vh;
    }
}

@media (min-width: 3440px) {
    .hero-section {
        max-height: 45vh;
        /* Controle máximo para ultrawide 21:9+ */
    }

    .hero-image {
        max-height: 45vh;
    }
}

/* Seção de Propagandas */
.propaganda-section {
    padding: 4rem 0;
    background: #fff3d8;
    /* Creme suave para fundo */
}

.propaganda-section .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.propaganda-item {
    height: 200px;
    background: #ecba78;
    /* Dourado claro para fundo dos itens */
    position: relative;
    display: flex;
    align-items: center;
    border-radius: 8px;
    justify-content: center;
    color: #523827;
    /* Marrom profundo para texto */
    font-weight: 500;
    overflow: hidden;
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
}

.propaganda-item h3 {
    font-size: 1.5rem;
    font-weight: 500;
}

/* Museus em Destaque */
.museus-destaque {
    padding: 4rem 0;
    background: #fff3d8;
    /* Creme suave para fundo */
}

.section-title {
    text-align: center;
    margin: 0 0 2.5rem 0;
    color: #523827;
    /* Marrom profundo para títulos */
    font-size: 2.2rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    position: relative;
    padding-bottom: 15px;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: linear-gradient(90deg, #9f643d, #cb8659);
    /* Gradiente de marrom médio para marrom-alaranjado */
    border-radius: 3px;
}

.museus-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.museu-card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
}

.museu-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.2);
}

.museu-image {
    height: 200px;
    background: #ecba78;
    /* Dourado claro para fundo das imagens */
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #523827;
    /* Marrom profundo para texto */
    font-weight: 500;
    overflow: hidden;
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
}

.museu-card h3 {
    padding: 1.5rem;
    font-size: 1.3rem;
    color: #523827;
    /* Marrom profundo para títulos */
    text-align: center;
}

.btn-ver-mais {
    display: block;
    width: fit-content;
    margin: 0 auto 1.5rem;
    padding: 0.8rem 2rem;
    background: #9f643d;
    /* Marrom médio para botões */
    color: white;
    text-decoration: none;
    border-radius: 5px;
    transition: background 0.3s;
}

.btn-ver-mais:hover {
    background: #cb8659;
    /* Marrom-alaranjado para hover */
}

/* Notícias */
.noticias {
    padding: 4rem 0;
    background: #fff3d8;
    /* Dourado claro para fundo */
}

.noticias-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.noticia-card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: transform 0.3s;
}

.noticia-card:hover {
    transform: translateY(-3px);
}

.noticia-image {
    height: 150px;
    background: #9f643d;
    /* Marrom médio para fundo das imagens */
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 500;
}

.noticia-card h3 {
    padding: 1rem 1.5rem 0.5rem;
    color: #523827;
    /* Marrom profundo para títulos */
    font-size: 1.2rem;
}

.noticia-card p {
    padding: 0 1.5rem;
    color: #634b43;
    /* Marrom acinzentado para texto */
    line-height: 1.6;
}

.btn-ler-mais {
    display: inline-block;
    margin: 1rem 1.5rem 1.5rem;
    padding: 0.6rem 1.5rem;
    background: #9f643d;
    /* Marrom médio para botões */
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-size: 0.9rem;
    transition: background 0.3s;
}

.btn-ler-mais:hover {
    background: #cb8659;
    /* Marrom-alaranjado para hover */
}

/* Footer */
.footer {
    background: #ecba78;
    /* Azul petróleo escuro para footer */
    color: white;
    padding: 3rem 0 1rem;
}

.footer .container {
    max-width: 1600px; /* Aumentar largura para acomodar todas as logos */
}

/* Footer-marcas */
.footer-marcas {
    background: #ecba78;
    /* Fundo igual ao .footer para estender até "Realização/Parcerias" */
    color: white;
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    align-items: start;
    text-align: center;
}

/* Footer com uma única seção (index.html) */
.footer-content.single-section {
    grid-template-columns: 1fr;
    justify-items: center;
}

/* Garantir alinhamento perfeito entre section-title e footer h4 */
.section-title,
.footer-section h4 {
    text-align: center;
    position: relative;
    display: block;
    width: 100%;
}

.section-title::after,
.footer-section h4::after {
    left: 50%;
    transform: translateX(-50%);
}

@media (max-width: 768px) {
    .footer-content {
        grid-template-columns: 1fr;
        gap: 1rem;
        text-align: center;
    }
}

.footer-section h4 {
    text-align: center;
    margin: 0 0 1rem 0; /* Reduzido de 2rem para 1rem - menor distância entre título e logos */
    color: #523827;
    /* Marrom profundo igual ao section-title */
    font-size: 1.8rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    position: relative;
    padding-bottom: 15px;
}

/* Adicionar espaço entre seções de Realização e Parcerias */
.footer-section + .footer-section {
    margin-top: 3rem; /* Mantém distância entre blocos */
}

.footer-section h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: linear-gradient(90deg, #9f643d, #cb8659);
    /* Mesmo gradiente do section-title */
    border-radius: 3px;
}

.footer-section ul {
    list-style: none;
}

.footer-section p {
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: white;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-section a:hover {
    color: #ffe63d;
    /* Amarelo vibrante para hover */
}

.social-links {
    display: flex;
    gap: 1rem;
    padding: 10px;
}

.social-links a {
    display: inline-block;
    width: 100px;
    height: 100px;
    background: #4b6a88;
    /* Azul acinzentado médio para ícones */
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s;
}

.social-links a:hover {
    background: #ffe63d;
    /* Amarelo vibrante para hover */
    color: #873b4b;
}

.social-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 4rem;
}

.social-btn {
    width: 80px;
    height: 80px;
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
}

/* Cores originais para botões sociais */
.social-btn.facebook {
    background: #1877f2;
}

/* Azul Facebook */
.social-btn.instagram {
    background: #e4405f;
}

/* Rosa Instagram */
.social-btn.twitter {
    background: #1da1f2;
}

/* Azul Twitter */
.social-btn.whatsapp {
    background: #25d366;
}

/* Verde WhatsApp */

.social-btn:hover {
    background: #ffe63d;
    /* Amarelo vibrante para hover */
    color: #873b4b;
    /* Azul petróleo escuro para texto no hover */
}

.footer-bottom {
    text-align: center;
    /* padding-top: 1rem; */
    color: #523827;;
    /* Dourado claro para texto */
}

/* Responsividade */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: linear-gradient(135deg, #e6a75d 0%, #d49a5c 50%, #c68e5a 100%);
        flex-direction: column;
        padding: 1rem;
        box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    }

    .nav-menu.active {
        display: flex;
    }

    .banner-title {
        font-size: 2rem;
    }

    .banner-subtitle {
        font-size: 1rem;
    }

    .propaganda-section .container {
        grid-template-columns: 1fr;
    }

    .section-title {
        font-size: 1.5rem;
    }

    .museus-grid,
    .noticias-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }

    .banner {
        height: 50vh;
    }

    .banner-title {
        font-size: 1.8rem;
    }

    .propaganda-item {
        padding: 2rem;
        min-height: 150px;
    }

    .propaganda-item h3 {
        font-size: 1.2rem;
    }
}

/* Estilos para logos no footer */
.footer-section.logos {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 1rem;
}

.footer-logo {
    max-height: 70px;
    max-width: 150px;
    height: auto;
    width: auto;
    margin: 0;
    object-fit: contain;
}

.footer-logo-sti {
    max-height: 56px; /* 80% de 70px */
    max-width: 120px; /* 80% de 150px */
}

.footer-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.footer-logos {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: nowrap;
    width: 100%;
    gap: 2.5rem; /* Espaçamento amplo entre logos */
    margin-top: 0.4rem; /* Reduzido de 0.5rem para 0.2rem - logos mais próximas do título */
    margin-bottom: 2rem; /* Espaço entre logos de realização e título "PARCERIAS" */
}

@media (max-width: 768px) {
    .footer-section.logos {
        justify-content: center;
    }

    .footer-logos {
        flex-wrap: wrap; /* Em mobile, pode quebrar */
    }
}


/* Ocultar cards vazios do Elementor quando não há notícias */
.elementor-widget-posts:empty,
.elementor-widget-loop-grid:empty,
.elementor-posts-container:empty {
    display: none !important;
}

/* Ocultar seção inteira quando não há posts */
.elementor-widget-posts:has(.elementor-posts-nothing-found),
.elementor-widget-loop-grid:has(.elementor-loop-message) {
    display: none !important;
}

/* Ocultar container de posts quando vazio */
.elementor-posts-container:not(:has(.elementor-post)),
.elementor-loop-container:not(:has(.elementor-loop-item)) {
    display: none !important;
}

/* Ocultar widget de posts quando não tem conteúdo */
.elementor-widget-posts:not(:has(.elementor-post)),
.elementor-widget-loop-grid:not(:has(.elementor-loop-item)) {
    display: none !important;
}

/* Estilizar mensagem de "não há notícias" caso seja exibida */
.elementor-widget-posts .elementor-posts-nothing-found,
.elementor-loop-container .elementor-loop-message {
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 2rem;
    text-align: center;
    color: #8b7355;
    font-size: 1.1rem;
    margin: 2rem 0;
}

/* Ocultar cards de post vazios */
.elementor-post:not(:has(*)),
.elementor-post:empty,
.elementor-loop-item:not(:has(*)),
.elementor-loop-item:empty {
    display: none !important;
}

/* Ocultar seção de notícias quando o título existe mas não há posts */
.elementor-section:has(> .elementor-container > .elementor-column > .elementor-widget-wrap > .elementor-widget-posts:not(:has(.elementor-post))) {
    display: none !important;
}

.elementor-section:has(> .elementor-container > .elementor-column > .elementor-widget-wrap > .elementor-widget-loop-grid:not(:has(.elementor-loop-item))) {
    display: none !important;
}

/* Garantir que a seção de notícias tenha altura mínima quando há conteúdo */
.elementor-widget-posts:has(.elementor-post),
.elementor-widget-loop-grid:has(.elementor-loop-item) {
    min-height: 100px;
}


/* ========================================
   CORREÇÃO CRÍTICA: Remover margin negativo de seções Elementor
   ======================================== */

/* Forçar remoção de margin negativo em TODAS as seções do Elementor */
.elementor-section[style*="margin-top: -"],
.elementor-section[style*="margin-top:-"],
.elementor-section[data-settings*="margin_top"],
section.elementor-section[style*="margin"] {
    margin-top: 0 !important;
}

/* Garantir que seção de Acervo em Destaque não tenha margin negativo */
.elementor-section:has(.gallery-section),
.elementor-section:has(h2:contains("ACERVO")),
section:has(.gallery-section) {
    margin-top: 0 !important;
    margin-bottom: 0 !important;
}

/* Garantir que seção de Notícias não deixe espaço quando oculta */
.elementor-section:has(.elementor-widget-posts:not(:has(.elementor-post))),
.elementor-section:has(.elementor-widget-loop-grid:not(:has(.elementor-loop-item))) {
    display: none !important;
    margin: 0 !important;
    padding: 0 !important;
    height: 0 !important;
    min-height: 0 !important;
}

/* Forçar espaçamento correto entre seções adjacentes */
.elementor-section + .elementor-section {
    margin-top: 0 !important;
}

/* Prevenir sobreposição de seções */
.elementor-section {
    position: relative !important;
    z-index: auto !important;
    clear: both !important;
}
