/* Estilos Globais */
:root {
    --primary-color: #003366; /* Azul Corporativo (cor do logo) */
    --secondary-color: #f3f4f6; /* Cinza Claro (usado em alguns itens) */
    --dark-color: #333;
    --light-color: #fff;
    --font-title: 'Playfair Display', serif;
    --font-body: 'Montserrat', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    line-height: 1.6;
    background-color: var(--primary-color); /* Fundo principal azul */
    color: #f0f0f0;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 30px;
}

h1, h2, h3, h4 {
    font-family: var(--font-title);
    font-weight: 700;
}

h3 {
    color: var(--light-color);
    text-align: center;
}

/* Cabeçalho */
header {
    background: var(--light-color); 
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    padding: 1rem 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header nav ul {
    list-style: none;
    display: flex;
    align-items: center;
}

header nav ul li {
    margin-left: 20px;
}

header nav ul li a {
    text-decoration: none;
    color: var(--dark-color);
    font-weight: 700;
    transition: color 0.3s;
}

header nav ul li a:hover {
    color: #555;
}

/* Seletor de Idioma */
.language-switcher a {
    display: flex;
    align-items: center;
    padding: 0;
    background: none;
}

.language-switcher img {
    width: 30px;
    height: auto;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    transition: transform 0.2s;
}

.language-switcher a:hover img {
    transform: scale(1.1);
}

/* Seção Hero */
.hero {
    background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url('https://images.unsplash.com/photo-1542744173-8e7e53415bb0?q=80&w=2070&auto-format&fit=crop&ixlib-rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D') no-repeat center center/cover;
    color: var(--light-color);
    height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding-top: 80px;
}

.hero h2 {
    font-size: 3.5rem;
    color: var(--light-color);
    margin-bottom: 1rem;
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    text-align: center;
}

.cta-button {
    background: var(--light-color);
    color: var(--primary-color);
    padding: 15px 30px;
    text-decoration: none;
    font-weight: 700;
    border-radius: 5px;
    transition: background-color 0.3s;
    border: none;
    cursor: pointer;
    font-family: var(--font-body);
}

.cta-button:hover {
    background: #e0e0e0; 
}

/* Seções Gerais */
.section {
    padding: 80px 0;
    text-align: center;
    position: relative;
    scroll-margin-top: 120px; /* Evita que o menu cubra o título */
}

.section h3 {
    font-size: 2.5rem;
    margin-bottom: 30px;
}

.section p {
    font-size: 1.1rem;
    max-width: 800px;
    margin: 0 auto 1.5rem auto;
    text-align: justify;
}

/* Grid de Serviços, MVV e Expertise (caixas brancas) */
.services-grid, .mvv-grid, .expertise-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-top: 50px;
}

/* Expertise específico para 2 colunas no desktop */
.expertise-grid {
    grid-template-columns: repeat(2, 1fr);
}

.service-item, .mvv-item, .expertise-item {
    background: var(--light-color); 
    color: var(--dark-color); 
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
    text-align: center;
}

.service-item p, .mvv-item p, .expertise-item p {
    text-align: center;
    font-size: 1rem;
}

.service-item:hover, .mvv-item:hover, .expertise-item:hover {
    transform: translateY(-5px);
}

.service-item h4, .mvv-item h4, .expertise-item h4 {
    color: var(--primary-color); 
    font-size: 1.5rem;
    margin-bottom: 10px;
    text-align: center;
}

.mvv-item i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 15px;
}

/* Expertise Intro */
.expertise-intro {
    font-style: italic;
    color: #ccc;
    margin-bottom: 40px !important;
    text-align: justify !important;
}

/* Seção Portfólio */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-top: 50px;
}

.portfolio-item {
    display: block;
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    aspect-ratio: 4 / 3;
    text-decoration: none;
}

.portfolio-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 51, 102, 0.85);
    color: var(--light-color);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.portfolio-overlay h4 {
    color: var(--light-color);
    margin: 0;
    font-size: 1.5rem;
}

.portfolio-overlay p {
    margin-top: 5px;
    font-size: 1rem;
    text-align: center !important;
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
}

.portfolio-item:hover img {
    transform: scale(1.1);
}

/* Seção de Contato */
#contato p {
    text-align: center !important;
}

#contato .email-contact,
#contato .whatsapp-contact {
    margin-top: 15px;
    font-size: 1.2rem;
    font-weight: 700;
}

#contato .email-contact {
    margin-top: 30px;
}

#contato a {
    color: var(--light-color); 
    text-decoration: underline;
}

/* Rodapé */
footer {
    background: #111;
    color: #aaa;
    text-align: center;
    padding: 20px 0;
    border-top: 3px solid var(--primary-color);
}

/* Estilo para a imagem do logo */
.logo-link img.logo {
    height: 65px; 
    width: auto;
}

/* Estilos para o rodapé com o link social */
.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap; 
}
.footer-social {
    min-height: 29px;
}

/* Estilos para os Ícones Flutuantes */
.floating-container {
    position: fixed;
    bottom: 25px;
    right: 25px;
    z-index: 1000;
    display: flex;
    gap: 15px;
}
.floating-btn {
    width: 60px;
    height: 60px;
    color: #FFF;
    border-radius: 50%;
    font-size: 30px;
    box-shadow: 2px 2px 8px rgba(0, 0, 0, 0.25);
    text-decoration: none;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: transform 0.2s ease;
}
.floating-btn:hover {
    transform: scale(1.1);
}
.whatsapp-btn {
    background-color: #25D366;
}
.instagram-btn {
    background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fdf497 5%, #fd5949 45%,#d6249f 60%,#285AEB 90%);
}

/* ================================================= */
/* == RESPONSIVIDADE E MENU MOBILE == */
/* ================================================= */

/* Botão Hambúrguer - escondido no desktop */
.hamburger {
    display: none;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0;
}

.hamburger .bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    background-color: var(--dark-color);
    transition: all 0.3s ease-in-out;
}

@media (max-width: 992px) {
    /* Tablets e telas médias */
    .services-grid, 
    .mvv-grid, 
    .expertise-grid, 
    .portfolio-grid {
        grid-template-columns: 1fr; /* Força 1 coluna aqui também */
    }
}

@media (max-width: 768px) {
    /* Ajustes para celulares */
    header .container {
        flex-direction: row; /* CORREÇÃO: Logo e Menu lado a lado */
        justify-content: space-between;
    }

    /* Ajuste fino do logo no mobile para não brigar com o menu */
    .logo-link img.logo {
        height: 55px;
    }

    .hero h2 {
        font-size: 2.5rem;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 15px;
    }

    /* Garante que Expertise e Portfolio fiquem em 1 coluna no mobile */
    .expertise-grid, .portfolio-grid {
        grid-template-columns: 1fr;
    }

    /* Menu Hambúrguer visível */
    .hamburger {
        display: flex;
        flex-direction: column;
    }

    /* Menu Dropdown Mobile */
    #main-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: white;
        box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    }

    #main-nav.menu-open {
        display: block;
    }

    header nav ul {
        flex-direction: column;
        width: 100%;
        align-items: stretch;
    }

    header nav ul li {
        margin: 0;
        text-align: center;
        border-bottom: 1px solid #f0f0f0;
    }

    header nav ul li a {
        display: block;
        padding: 1rem;
    }
    
    /* CORREÇÃO: Centralizar a bandeira no mobile */
    .language-switcher a {
        justify-content: center; /* Centraliza o conteúdo flex (a bandeira) */
        width: 100%;
    }

    /* Animação do X do menu */
    .hamburger.is-active .bar:nth-child(2) { opacity: 0; }
    .hamburger.is-active .bar:nth-child(1) { transform: translateY(8px) rotate(45deg); }
    .hamburger.is-active .bar:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
}