/* ====================
   VARIÁVEIS E ESTILOS GLOBAIS
   ==================== */
:root {
    --primary-color: #0d2c4f;
    --secondary-color: #008037;
    --accent-color: #f39200;
    --text-color: #333;
    --light-gray: #f4f7f6;
    --white: #ffffff;
    --header-height: 80px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    background-color: var(--white);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

img {
    max-width: 100%;
    height: auto;
}

/* ====================
   CABEÇALHO
   ==================== */
header {
    background: var(--white);
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

.header-top-bar {
    background-color: var(--primary-color);
    color: var(--white);
    padding: 5px 0;
    font-size: 0.8rem;
}

.header-top-bar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.social-icons a {
    color: var(--white);
    margin-left: 15px;
    transition: color 0.3s ease;
}
.social-icons a:hover {
    color: var(--accent-color);
}

.main-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: var(--header-height);
}

.logo img {
    height: 200px;
}

.main-nav ul {
    list-style: none;
    display: flex;
    gap: 30px;
}

.main-nav a {
    text-decoration: none;
    color: var(--primary-color);
    font-weight: 600;
    position: relative;
    padding-bottom: 5px;
}

.main-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 3px;
    background-color: var(--secondary-color);
    transition: width 0.3s ease;
}

.main-nav a:hover::after, .main-nav li.active a::after {
    width: 100%;
}

.mobile-menu-toggle { display: none; }

/* ====================
   SEÇÃO HERO (HOME)
   ==================== */
#hero {
    background-image: linear-gradient(rgba(13, 44, 79, 0.8), rgba(13, 44, 79, 0.8)), url('https://images.unsplash.com/photo-1554224155-1696413565d3?q=80&w=2070&auto=format&fit=crop');
    background-size: cover;
    background-position: center;
    color: var(--white);
    min-height: 600px;
    display: flex;
    align-items: center;
    text-align: center;
    padding-top: var(--header-height);
}

#hero h1 {
    font-family: 'Raleway', sans-serif;
    font-size: 3.5rem;
    margin-bottom: 20px;
}

#hero h1 span {
    color: var(--accent-color);
}

#hero p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto 30px;
}

/* ====================
   PÁGINAS INTERNAS - TÍTULO
   ==================== */
.page-title-section {
    padding: 120px 0 60px;
    background-color: var(--light-gray);
    text-align: center;
}
.page-title-section h1 {
    font-family: 'Raleway', sans-serif;
    color: var(--primary-color);
    font-size: 3rem;
}


/* ====================
   ESTILOS GERAIS DE SEÇÃO
   ==================== */
section {
    padding: 80px 0;
}

.section-title {
    text-align: center;
    font-family: 'Raleway', sans-serif;
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 50px;
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: var(--accent-color);
    margin: 10px auto 0;
}

.section-title.left-aligned {
    text-align: left;
}
.section-title.left-aligned::after {
    margin: 10px 0 0;
}
.section-subtitle {
    text-align: center;
    font-size: 1.1rem;
    color: #666;
    max-width: 700px;
    margin: -30px auto 50px;
}

.light-bg {
    background: var(--light-gray);
}


/* ====================
   BOTÕES E LAYOUTS
   ==================== */
.cta-button {
    background: var(--secondary-color);
    color: var(--white);
    padding: 12px 28px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 700;
    transition: all 0.3s ease;
    display: inline-block;
    border: 2px solid transparent;
}
.cta-button:hover {
    background: #00662c;
    transform: translateY(-3px);
}
.cta-button.secondary {
    background: transparent;
    color: var(--secondary-color);
    border: 2px solid var(--secondary-color);
}
.cta-button.secondary:hover {
    background: var(--secondary-color);
    color: var(--white);
}

.two-columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}
.two-columns img {
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

/* ====================
   SERVIÇOS E FEATURES
   ==================== */
#servicos .services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
}
.service-card {
    background: var(--white);
    padding: 30px;
    border: 1px solid #eee;
    border-radius: 10px;
    text-align: center;
    transition: all 0.3s ease;
}
.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.08);
}
.service-card i {
    font-size: 2.5rem;
    color: var(--secondary-color);
    margin-bottom: 15px;
}
.service-card h3 {
    font-size: 1.1rem;
    color: var(--primary-color);
    min-height: 45px;
}

#porque-nos .features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}
.feature-item {
    text-align: center;
}
.feature-item i {
    font-size: 2.5rem;
    color: var(--accent-color);
    margin-bottom: 15px;
}
.feature-item h3 {
    font-size: 1.2rem;
    margin-bottom: 10px;
    color: var(--primary-color);
}

/* ====================
   PÁGINA DE CONTATO
   ==================== */
#contact-page .contact-method {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 25px;
}
#contact-page .contact-method i {
    font-size: 2rem;
    color: var(--secondary-color);
    width: 40px;
}
#contact-page .contact-method a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 600;
}
#contact-page .contact-method a:hover {
    text-decoration: underline;
}

.contact-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
}
.contact-form input, .contact-form textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 5px;
    margin-bottom: 15px;
}
.contact-form button {
    width: 100%;
    border: none;
    cursor: pointer;
}

/* ====================
   CTA FINAL E RODAPÉ
   ==================== */
#cta-final {
    background: var(--primary-color);
    color: var(--white);
    text-align: center;
}
#cta-final h2 {
    color: var(--white);
    font-size: 2.2rem;
    margin-bottom: 15px;
}
#cta-final .cta-button {
    background: var(--accent-color);
}
#cta-final .cta-button:hover {
    background: #d98200;
}

footer {
    /* MUDANÇA 1: Fundo para cinza claro */
    background: #f0f0f0;
    
    /* MUDANÇA 2: Cor padrão do texto para o azul marinho da marca */
    color: var(--primary-color);
    
    padding-top: 60px;
}
.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    padding-bottom: 40px;
}
.footer-logo {
    height: 215px;
    margin-bottom: 15px;
}
.footer-col h4 {
    /* MUDANÇA 3: Cor dos títulos para azul marinho */
    color: var(--primary-color);
    font-family: 'Raleway', sans-serif;
    margin-bottom: 15px;
}
.footer-col ul {
    list-style: none;
}
.footer-col a {
    /* MUDANÇA 4: Cor dos links para azul marinho */
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
    line-height: 2;
}
.footer-col a:hover {
    /* Efeito extra: O link fica verde ao passar o mouse */
    color: var(--secondary-color);
}
.footer-bottom {
    /* MUDANÇA 5: Cor da linha divisória para um cinza que combina com o fundo */
    border-top: 1px solid #dcdcdc;
    padding: 20px 0;
    text-align: center;
    font-size: 0.9rem;
}

/* ====================
   ANIMAÇÕES E RESPONSIVIDADE
   ==================== */
.reveal {
  opacity: 0;
  transform: translateY(50px);
  transition: all 1s ease;
}
.reveal.active {
  opacity: 1;
  transform: translateY(0);
}


/* --- INÍCIO DAS REGRAS PARA TELAS MENORES (MOBILE) --- */
@media (max-width: 768px) {
    
    /* --- AJUSTES GERAIS PARA MOBILE --- */
    section {
        padding: 60px 0; /* Diminui o espaçamento das seções */
    }

    #hero h1, .page-title-section h1 { 
        font-size: 2.2rem; /* Diminui o tamanho dos títulos principais */
        line-height: 1.3;
    }
    
    .section-title {
        font-size: 2rem;
    }

    .two-columns, .footer-grid {
        grid-template-columns: 1fr; /* Colunas ficam uma sobre a outra */
        gap: 30px;
    }


    /* --- ESTILOS DO MENU MOBILE --- */
    
    /* Oculta o menu de navegação por padrão */
    .main-nav { 
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        
        position: fixed;
        top: 0;
        right: -100%; /* Começa escondido fora da tela */
        width: 80%;
        height: 100vh;
        
        background-color: var(--primary-color);
        box-shadow: -5px 0 15px rgba(0,0,0,0.2);
        
        transition: right 0.4s ease-in-out; /* Animação de deslize */
        z-index: 1001; /* Fica acima do conteúdo, mas abaixo do botão */
    }
    
    /* Classe que o JavaScript adiciona para ABRIR o menu */
    .main-nav.mobile-menu-open {
        right: 0; /* Traz o menu para a tela */
    }
    
    .main-nav ul {
        flex-direction: column; /* Links um abaixo do outro */
        width: 100%;
        text-align: center;
        gap: 0;
    }
    
    .main-nav li {
        width: 100%;
    }
    
    .main-nav a {
        color: var(--white);
        display: block;
        padding: 20px;
        font-size: 1.1rem;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .main-nav a::after {
        display: none; /* Remove a linha animada do menu desktop */
    }
    
    /* Mostra o botão "hamburger" */
    .mobile-menu-toggle {
        display: block;
        background: none;
        border: none;
        color: var(--primary-color);
        font-size: 1.5rem;
        cursor: pointer;
        z-index: 1002; /* Fica acima de tudo */
        position: relative; /* Necessário para o z-index funcionar bem */
    }

    /* Trava a rolagem da página quando o menu está aberto */
    body.menu-open {
        overflow: hidden;
    }
}

/* Adicione ao final do css/style.css */
.form-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 5px;
    text-align: center;
}

.form-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 5px;
    text-align: center;
}

/* ====================
   ESTILOS DO BOTÃO DE ACESSO AO DASHBOARD
   ==================== */

.dashboard-access {
    display: flex;
    align-items: center;
    gap: 10px; /* Espaço entre os botões */
    margin-left: 20px; /* Espaço entre o menu e os botões */
}

/* Estilo para o ícone de Sair (logout) */
.logout-icon {
    font-size: 1.5rem;
    color: var(--primary-color);
    transition: color 0.3s ease;
}

.logout-icon:hover {
    color: #d9534f; /* Vermelho para a ação de sair */
}

/* Ajustes para o botão secundário (quando logado) */
.dashboard-access .cta-button.secondary {
    padding: 8px 16px;
    font-size: 0.9rem;
}

.dashboard-access .cta-button i {
    margin-right: 5px;
}


/* --- RESPONSIVIDADE PARA O BOTÃO DE ACESSO --- */
/* Em telas menores, esconde o botão de acesso do header principal */
@media (max-width: 900px) {
    .dashboard-access {
        display: none;
    }
}

/* =======================================
   ESTILOS MODERNOS PARA PÁGINAS DE ACESSO
   (Login, Cadastro, Esqueci a Senha)
   ======================================= */

/* Removemos o título padrão para essas páginas */
#auth-page .page-title-section {
    display: none;
}

/* O container que preenche a tela inteira */
.auth-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    width: 100%;
    /* Fundo com um gradiente sutil usando as cores da marca */
    background: linear-gradient(135deg, #eaf2f8, #f8f9fa);
    padding: 20px;
}

/* A caixa principal que divide em duas colunas */
.auth-box {
    display: grid;
    grid-template-columns: 1fr 1fr;
    max-width: 900px;
    width: 100%;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 15px 40px rgba(0, 40, 80, 0.15);
    overflow: hidden; /* Garante que os cantos arredondados funcionem */
}

/* Coluna da Esquerda: Promoção da Marca */
.auth-promo {
    background: var(--primary-color); /* Azul escuro da marca */
    color: #fff;
    padding: 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: center;
}

.auth-promo img.logo {
    max-width: 200px;
    margin: 0 auto 20px;
}

.auth-promo h2 {
    font-family: 'Raleway', sans-serif;
    font-size: 1.8rem;
    margin-bottom: 15px;
}

.auth-promo p {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.8);
}

/* Coluna da Direita: Formulário */
.auth-form {
    padding: 40px;
}

.auth-form h3 {
    font-family: 'Raleway', sans-serif;
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.auth-form p.subtitle {
    color: #777;
    margin-bottom: 30px;
}

.auth-form form label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #555;
}

.auth-form form input[type="text"],
.auth-form form input[type="email"],
.auth-form form input[type="password"] {
    width: 100%;
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 5px;
    margin-bottom: 15px;
    box-sizing: border-box;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

/* Efeito de foco nos campos */
.auth-form form input:focus {
    outline: none;
    border-color: var(--secondary-color); /* Verde da marca */
    box-shadow: 0 0 0 3px rgba(0, 128, 55, 0.1);
}

.auth-form form .cta-button {
    width: 100%;
    padding: 12px;
    margin-top: 10px;
    transition: transform 0.2s ease, background-color 0.3s ease;
}

.auth-form form .cta-button:hover {
    transform: scale(1.02);
}

.auth-form .auth-link {
    text-align: center;
    margin-top: 20px;
    font-size: 0.9rem;
}

.auth-form .auth-link a {
    color: var(--secondary-color);
    font-weight: 600;
    text-decoration: none;
}
.auth-form .auth-link a:hover {
    text-decoration: underline;
}

/* Responsividade para celulares */
@media (max-width: 768px) {
    .auth-box {
        grid-template-columns: 1fr; /* Colunas empilhadas */
    }
    .auth-promo {
        padding: 30px;
    }
    .auth-form {
        padding: 30px;
    }
}