/* Arquivo: css/style.css - Versão Completa */

:root {
    /* Cores do Tema */
    --primary-color: #0a4064; /* Verde Principal */
    --primary-dark: #2a7000;  /* Verde mais escuro para hover */
    --secondary-color: #f8f9fa; /* Fundo claro */
    --accent-color: #0a4064; /* Amarelo para detalhes */
    --text-color: #333;
    --text-light: #777;
    --header-bg: #fff;
    --border-color: #e1e1e1;
    --bg-color: #f4f4f4;
}

/* Reset Básico */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f0f2f5;
    color: var(--text-color);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* =========================================
   HEADER & NAVEGAÇÃO (Estilo Masthead)
   ========================================= */
header {
    background-color: var(--primary-color); /* Fundo Azul */
    padding: 1rem 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

.navbar {
    display: flex;
    flex-direction: column; /* Empilha: Logo em cima, Menu em baixo */
    align-items: center;
    justify-content: center;
}

/* Estilos da Logo (Imagem) */
.logo-link {
    display: inline-block;
    margin-bottom: 1rem;
    text-decoration: none;
    text-align: center;
}

.logo-img {
    max-width: 100%;
    height: auto;
    /* Define a altura máxima para não ficar gigante no desktop */
    max-height: 120px; 
    display: block;
}

/* Estilos do Menu */
.nav-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    width: 100%;
    border-top: 1px solid var(--border-color);
    padding: 0.8rem 0;
    background: #fff;
}

.nav-links a {
    text-decoration: none;
    color: #fff; /* Texto Branco */
    font-weight: 500;
    font-size: 1rem;
    transition: color 0.3s;
}

/* Efeito de sublinhado animado no menu */
.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 3px;
    bottom: -2px;
    left: 0;
    background-color: var(--primary-color);
    transition: width 0.3s;
}

.nav-links a:hover {
    color: #ffed00;
}

.menu-toggle i {
    color: #fff;
}

.nav-links a:hover::after {
    width: 100%;
}

/* =========================================
   LAYOUT PRINCIPAL (GRID)
   ========================================= */
.main-grid {
    display: grid;
    grid-template-columns: 2fr 1fr; /* Conteúdo: 66%, Sidebar: 33% */
    gap: 2rem;
    margin-top: 2rem;
    margin-bottom: 2rem;
}

/* =========================================
   COMPONENTES: CARDS DE NOTÍCIAS
   ========================================= */
.news-card {
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    margin-bottom: 1.5rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    border: 1px solid transparent;
}

.news-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    border-color: #eee;
}

/* Estilo especial para a notícia destaque (a primeira) */
.news-card.destaque .news-img {
    height: 350px; /* Imagem maior no destaque */
}

.news-card.destaque .news-title {
    font-size: 1.8rem;
}

.news-img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background-color: #ddd;
    display: block;
}

.news-content {
    padding: 1.5rem;
}

.news-meta {
    font-size: 0.85rem;
    color: var(--text-light);
    display: block;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.news-title {
    font-size: 1.3rem;
    margin-bottom: 0.8rem;
    line-height: 1.3;
}

.news-title a {
    text-decoration: none;
    color: var(--text-color);
    transition: color 0.2s;
}

.news-title a:hover {
    color: var(--primary-color);
}

.conteudo-resumo {
    color: #666;
    font-size: 1rem;
}

/* =========================================
   SIDEBAR & WIDGETS
   ========================================= */
aside {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.widget {
    background: #fff;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    border: 1px solid #f0f0f0;
}

.widget-title {
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 0.5rem;
    margin-bottom: 1.2rem;
    font-size: 1.1rem;
    color: var(--text-color);
    font-weight: 700;
    text-transform: uppercase;
}

/* Botões e Formulários */
.btn {
    display: inline-block;
    padding: 10px 20px;
    background-color: var(--primary-color);
    color: #fff;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 600;
    text-align: center;
    transition: background 0.3s;
    border: none;
    cursor: pointer;
}

.btn:hover {
    background-color: var(--primary-dark);
}

input[type="text"], 
input[type="email"], 
textarea {
    width: 100%;
    padding: 12px;
    margin-bottom: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: inherit;
}

input:focus, textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(53, 141, 0, 0.2);
}

/* =========================================
   FOOTER
   ========================================= */

footer p {
    margin-bottom: 0.5rem;
    opacity: 0.8;
}

/* =========================================
   RESPONSIVIDADE (CELULAR/TABLET)
   ========================================= */
@media (max-width: 768px) {
    /* Ajuste do Grid Principal */
    .main-grid {
        grid-template-columns: 1fr; /* Vira uma coluna só */
        gap: 1.5rem;
    }

    /* Ajuste da Logo */
    .logo-img {
        max-height: 90px; /* Logo menor no celular */
    }

    /* Ajuste do Menu */
    .navbar {
        padding-bottom: 0;
    }

    .nav-links {
        flex-direction: column;
        align-items: center;
        gap: 5px;
    }

    .nav-links a {
    text-decoration: none;
    color: #fff; /* Texto Branco */
    font-weight: 500;
    font-size: 1rem;
    transition: color 0.3s;
}
    
    .nav-links a::after {
        display: none; /* Remove a animação no mobile para simplificar */
    }

    .news-card.destaque .news-img {
        height: 250px;
    }
}

/* --- NOVOS ESTILOS PARA A HOME --- */

/* Grid de 3 Colunas para Notícias */
.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* 3 colunas iguais */
    gap: 20px;
    margin-bottom: 3rem;
}

/* Ajuste dos cards no grid pequeno */
.grid-3 .news-card {
    display: flex;
    flex-direction: column;
    margin-bottom: 0; /* Remove margem inferior padrão */
}

.grid-3 .news-img {
    height: 160px; /* Altura menor para caber bem */
}

.grid-3 .news-title {
    font-size: 1.1rem; /* Fonte um pouco menor */
}

/* Seção de Categorias */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #eee;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
}

.section-title {
    font-size: 1.5rem;
    color: var(--primary-color);
    border-bottom: 3px solid var(--primary-color);
    margin-bottom: -0.65rem; /* Faz a linha verde sobrepor a cinza */
    padding-bottom: 0.5rem;
    display: inline-block;
}

/* Seção Devocional (Destaque) */
.devocional-box {
    background: linear-gradient(135deg, var(--primary-color), #2a7000);
    color: #fff;
    padding: 3rem;
    border-radius: 8px;
    text-align: center;
    margin: 3rem 0;
    box-shadow: 0 5px 15px rgba(53, 141, 0, 0.3);
}

.devocional-box h2 { font-size: 2.5rem; margin-bottom: 1rem; }
.devocional-texto { font-size: 1.2rem; font-style: italic; margin-bottom: 1.5rem; line-height: 1.8; }

/* Responsividade para o Grid 3 */
@media (max-width: 768px) {
    .grid-3 { grid-template-columns: 1fr; } /* Vira 1 coluna no celular */
}

/* --- ATUALIZAÇÃO: TOP BAR & FOOTER ROBUSTO --- */

/* Barra de Topo (Social Header) */
.top-bar {
    background-color: #062a42;
    border-bottom: none;
    padding: 8px 0;
    font-size: 0.9rem;
    color: #ccc;
}

.top-bar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.social-top a {
    color: #ccc;
    margin-left: 15px;
    transition: color 0.3s;
    font-size: 1.1rem;
}

.social-top a:hover { color: #fff; }

/* Footer Robusto */
.main-footer {
    background-color: var(--primary-color) !important;
    color: #fff !important;
    padding: 4rem 0 2rem;
    margin-top: auto;
   border-top: 5px solid #ffed00;
    text-align: left !important; /* Força o alinhamento à esquerda */
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* 3 Colunas */
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-widget {
    text-align: left; /* Garante que os widgets fiquem à esquerda */
}

.footer-widget h4 {
    color: #fff !important;
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
    border-left: 3px solid #ffed00 !important;
    padding-left: 10px;
    text-transform: uppercase;
}

.footer-links ul {
    list-style: none !important;
    padding-left: 0 !important;
    margin: 0 !important;
}

.footer-links li {
    padding-left: 0;
    margin-bottom: 10px;
}

.footer-links a {
    color: #e0e0e0 !important;
    text-decoration: none;
    transition: all 0.3s;
}

.footer-links a:hover {
    color: #ffed00 !important;
    padding-left: 5px; /* Efeito de mover para direita */
}

/* Garante que os ícones de contato fiquem alinhados com o texto */
.footer-widget ul li {
    display: flex;
    align-items: center;
    justify-content: flex-start; /* Alinha ícone e texto à esquerda */
}

.footer-widget ul li i {
    margin-right: 10px; /* Espaço entre o ícone e o texto */
    min-width: 20px;    /* Garante alinhamento vertical */
}

.footer-social a {
    background: rgba(255,255,255,0.1);
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    background: #333;
    color: #fff;
    border-radius: 50%;
    margin-right: 10px;
    text-decoration: none;
    transition: background 0.3s;
}

.footer-social a:hover { background: #ffed00;
    color: var(--primary-color); /* Ícone fica azul no hover */ }

.copyright {
    text-align: center !important;
    border-top: 1px solid rgba(255,255,255,0.1) !important;
    color: #ccc;
    padding-top: 2rem;
    margin-top: 3rem;
    font-size: 0.9rem;
}

/* Responsividade do Footer */
@media (max-width: 768px) {
    .footer-grid { grid-template-columns: 1fr; } /* 1 coluna no telemóvel */
    .top-bar .date-display { display: none; } /* Esconde data no telemóvel para poupar espaço */
    .top-bar .container { justify-content: center; }
}

/* --- SISTEMA DE COOKIES (LGPD) --- */
.cookie-banner {
    position: fixed;
    bottom: -100px; /* Começa escondido */
    left: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.9); /* Fundo escuro quase transparente */
    color: #fff;
    padding: 15px 20px;
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.3);
    transition: bottom 0.5s ease-in-out; /* Efeito de deslizar */
    border-top: 2px solid var(--primary-color);
}

.cookie-banner.mostrar {
    bottom: 0; /* Aparece na tela */
}

.cookie-text {
    font-size: 0.9rem;
    max-width: 800px;
}

.btn-cookie {
    background: var(--primary-color);
    color: #fff;
    border: none;
    padding: 8px 25px;
    border-radius: 50px;
    font-weight: bold;
    cursor: pointer;
    transition: transform 0.2s;
    white-space: nowrap;
}

.btn-cookie:hover {
    transform: scale(1.05);
    background: #2a7000;
}

/* Responsivo para celular */
@media (max-width: 768px) {
    .cookie-banner {
        flex-direction: column;
        text-align: center;
        padding: 20px;
    }
}

/* Estilo do link dentro do banner de cookies */
.cookie-text a {
    color: var(--primary-color); /* Verde do site */
    text-decoration: underline;
    font-weight: bold;
}

.cookie-text a:hover {
    color: #fff; /* Fica branco ao passar o mouse */
}

/* --- PÁGINA DE CONTATO --- */

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr; /* Coluna Info menor, Form maior */
    gap: 2rem;
    background: #fff;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

/* Caixa de Informações (Esquerda) */
.contact-info-box h3 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    border-bottom: 2px solid #eee;
    padding-bottom: 10px;
}

.info-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1.5rem;
}

.info-item i {
    background: var(--primary-color);
    color: #fff;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    font-size: 1.1rem;
}

.info-item strong {
    display: block;
    color: #333;
    font-size: 1.1rem;
}

.info-item span {
    color: #666;
}

.social-contact a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 45px;
    height: 45px;
    background: #f0f2f5;
    color: #555;
    border-radius: 5px;
    margin-right: 10px;
    text-decoration: none;
    transition: all 0.3s;
    font-size: 1.2rem;
}

.social-contact a:hover {
    background: var(--primary-color);
    color: #fff;
}

/* Caixa de Formulário (Direita) */
.contact-form-box h3 {
    margin-bottom: 1.5rem;
}

/* Responsividade */
@media (max-width: 768px) {
    .contact-grid {
        grid-template-columns: 1fr; /* Vira 1 coluna no celular */
        padding: 1.5rem;
    }
    
    .contact-info-box {
        margin-bottom: 2rem;
    }
}

/* --- CARROSSEL DE EVENTOS --- */
.evento-card {
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    position: relative;
    transition: transform 0.3s;
    /* Altura automática para se ajustar ao conteúdo */
    height: auto; 
}

.evento-card:hover { transform: translateY(-5px); }

.evento-img-container {
    width: 100%;
    /* Define a proporção exata de 16 por 9 */
    aspect-ratio: 16 / 9; 
    /* Remove a altura fixa antiga de 200px */
    height: auto; 
    overflow: hidden;
    position: relative;
    background: #000; /* Fundo preto caso a imagem demore a carregar */
}

.evento-img-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.evento-data {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #fff;
    padding: 5px 10px;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    z-index: 10;
}

.evento-data .dia { display: block; font-size: 1.2rem; font-weight: bold; color: var(--primary-color); }
.evento-data .mes { display: block; font-size: 0.8rem; text-transform: uppercase; color: #555; }

.evento-info { padding: 15px; }
.evento-info h3 {
    font-size: 1.1rem;
    color: #333;
    margin-bottom: 10px;
    
    /* Mágica para limitar a 2 linhas e por reticências (...) */
    display: -webkit-box;
    -webkit-line-clamp: 2; /* Número máximo de linhas */
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    
    /* Define uma altura fixa para manter o alinhamento dos botões */
    line-height: 1.3; /* Altura de cada linha */
    height: 2.6rem;   /* Altura total (1.3 * 2 linhas) */
}
.evento-info p { font-size: 0.9rem; color: #666; margin-bottom: 5px; }

.btn-evento {
    display: block;
    background: var(--primary-color);
    color: #fff;
    text-align: center;
    padding: 8px;
    border-radius: 4px;
    text-decoration: none;
    margin-top: 10px;
    font-size: 0.9rem;
}
.btn-evento:hover { background: #2a7000; }

/* Ajuste das setas do Swiper para serem verdes */
.swiper-button-next, .swiper-button-prev { color: var(--primary-color) !important; }
.swiper-pagination-bullet-active { background: var(--primary-color) !important; }

/* --- PÁGINA DE EVENTOS (GRID) --- */
.grid-eventos-page {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* 3 Colunas */
    gap: 30px;
}

.evento-card-page {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s;
    display: flex;
    flex-direction: column;
}

.evento-card-page:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
}

.evento-thumb {
    height: 200px;
    position: relative;
    overflow: hidden;
}

.evento-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.evento-card-page:hover .evento-thumb img { transform: scale(1.05); }

.data-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: #fff;
    padding: 8px 12px;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
    z-index: 10;
}

.data-badge .dia { display: block; font-size: 1.4rem; font-weight: 800; color: #333; line-height: 1; }
.data-badge .mes { display: block; font-size: 0.75rem; text-transform: uppercase; color: var(--primary-color); font-weight: bold; }

.evento-content { padding: 20px; flex-grow: 1; display: flex; flex-direction: column; }

.evento-title { font-size: 1.25rem; margin-bottom: 10px; color: #222; }

.evento-local { color: #666; margin-bottom: 20px; font-size: 0.95rem; flex-grow: 1; }

.btn-ingresso {
    text-align: center;
    background: var(--primary-color);
    color: #fff;
    padding: 10px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    transition: background 0.2s;
}

.btn-ingresso:hover { background: #2a7000; }

/* Responsividade */
@media (max-width: 900px) {
    .grid-eventos-page { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
    .grid-eventos-page { grid-template-columns: 1fr; }
}

/* --- FUNDO DE VÍDEO (Mundo da Música) --- */

.section-musica {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.video-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    overflow: hidden;
}

.video-background video {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Garante que o vídeo cubra tudo sem distorcer */
}

/* Película escura para o texto ficar legível em cima do vídeo */
.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5); /* 50% de transparência preta */
    z-index: 2;
}

/* Ajustes nos cards quando estiverem sobre o vídeo */
.section-musica .news-card:hover {
    transform: translateY(-5px);
    border-color: #fff !important;
}

/* Ajuste do botão ver mais na sessão de música */
.section-musica .btn:hover {
    background: #eee !important;
    color: #333 !important;
}

/* --- CORREÇÃO DO MENU E HEADER --- */

/* Força o container do menu a ser transparente (para aparecer o azul do header) */
header .navbar {
    background-color: transparent !important; 
    display: flex;
    flex-direction: column; /* Coloca a logo em cima e menu em baixo */
    align-items: center;    /* Centraliza tudo */
    padding-bottom: 10px;
}

/* Garante que a área dos links não tenha fundo branco */
.nav-links {
    background-color: transparent !important;
    margin-top: 15px; /* Espaço entre a logo e o menu */
    display: flex;
    gap: 20px; /* Espaço entre os links */
    flex-wrap: wrap;
    justify-content: center;
}

/* Garante que os links sejam BRANCOS e visíveis */
.nav-links a {
    color: #ffffff !important;
    font-weight: 500;
    text-transform: uppercase;
    font-size: 0.9rem;
    padding: 5px 10px;
    border-radius: 4px;
}

/* Efeito ao passar o mouse (Amarelo) */
.nav-links a:hover {
    color: #0a4064 !important; /* Texto vira azul */
    background-color: #ffed00;  /* Fundo vira amarelo */
}

/* --- AJUSTES FINAIS: LOGOS E BOTÕES AMARELOS --- */

/* 1. AUMENTAR LOGO DO HEADER */
/* Aumenta a altura máxima para a logo ficar maior na barra azul */
header .logo-img {
    max-height: 140px;       /* Aumentado para ficar bem visível */
    width: auto;             /* Mantém a proporção correta */
    margin: 10px 0;          /* Espaço em cima e embaixo */
    filter: none !important; /* Garante que nenhum filtro branco seja aplicado */
}

header .navbar {
    padding-bottom: 20px;
}

/* 2. AUMENTAR LOGO DO FOOTER */
/* Aumenta a largura da logo no rodapé */
.footer-widget img {
    max-width: 280px !important; /* Aumentado de 220px para 280px */
    width: 100%;                 /* Garante responsividade */
}

/* 3. HOVER DOS BOTÕES (DE VERDE PARA AMARELO) */
/* Aplica o amarelo em todos os botões do site ao passar o mouse */
.btn:hover, 
.btn-evento:hover, 
.btn-ingresso:hover, 
.btn-cookie:hover,
button:hover,
input[type="submit"]:hover {
    background-color: #ffed00 !important; /* Fundo Amarelo */
    color: #0a4064 !important;            /* Texto Azul Escuro (Para ler bem no amarelo) */
    border-color: #ffed00 !important;
    
    /* Efeito visual extra */
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(255, 237, 0, 0.3);
}

/* Ajuste específico para o botão de "Ver Mais" na home (Mundo da Música) */
.section-musica .btn:hover {
    background-color: #ffed00 !important;
    color: #0a4064 !important;
}

/* --- ÍCONES SOCIAIS DO FOOTER (PERSONALIZADO) --- */

.footer-social a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    margin-right: 10px;
    text-decoration: none;
    transition: all 0.3s ease;
    
    /* ESTADO NORMAL: Fundo Branco, Ícone Azul */
    background-color: #ffffff !important;
    color: var(--primary-color) !important; /* Azul #0a4064 */
}

.footer-social a:hover {
    /* ESTADO HOVER: Fundo Amarelo, Ícone Branco */
    background-color: #ffed00 !important;
    color: #ffffff !important;
    
    transform: translateY(-3px); /* Efeito de subir levemente */
    box-shadow: 0 4px 10px rgba(255, 237, 0, 0.4); /* Brilho amarelo */
}