/* Importação de fonte similar */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    /* Cores atualizadas para um visual mais moderno */
    --color-dark-bg: #101018; /* Fundo mais escuro */
    --color-mid-dark: #1e1e28; /* Fundo das caixas */
    --color-text-light: #ffffff;
    --color-text-mid: #a0a0ab;
    --color-accent: #00bcd4; /* Azul Ciano/Água para destaque */
    --color-line: #2a2a35;
    --font-primary: 'Inter', sans-serif;
    --padding-base: 20px;
}

/* Reset básico e tipografia */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-primary);
    background-color: var(--color-dark-bg);
    color: var(--color-text-light);
    line-height: 1.6;
    padding: 0 5vw; /* Padding lateral responsivo (5% da largura da tela) */
    overflow-x: hidden; /* Evita barra de rolagem horizontal indesejada */
}

a {
    text-decoration: none;
    color: var(--color-text-light);
    transition: color 0.3s;
}

/* Cabeçalho */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 30px 0;
    border-bottom: 1px solid var(--color-line);
}

.logo {
    font-size: 28px;
    font-weight: 800;
    color: var(--color-accent);
    letter-spacing: 2px;
}

.lg-img {
    width: 100px;
}

.navbar a {
    color: var(--color-text-mid);
    text-decoration: none;
    font-weight: 500;
    margin-left: 30px;
}

.navbar a:hover {
    color: var(--color-accent);
}

/* Seção Hero (Destaque) */
.hero-section {
    padding: 80px 0;
    border-bottom: 1px solid var(--color-line);
}

.hero-content {
    display: flex;
    gap: 60px;
    align-items: center; /* Alinha verticalmente */
}

.intro {
    flex: 1;
}

.section-tag {
    color: var(--color-accent);
    font-size: 14px;
    margin-bottom: 10px;
    font-weight: 600;
    text-transform: uppercase;
}

.name {
    font-size: 96px;
    line-height: 0.9;
    margin-bottom: 20px;
    font-weight: 800;
}

.role-location {
    font-size: 24px;
    font-weight: 600;
    color: var(--color-accent);
    margin-bottom: 20px;
}

.description {
    color: var(--color-text-mid);
    margin-bottom: 30px;
    max-width: 500px;
}

.hero-image-container {
    flex: 1;
    max-width: 400px; /* Limita o tamanho da imagem em desktop */
    clip-path: polygon(10% 0, 100% 0, 90% 100%, 0 100%); /* Novo recorte mais suave */
    overflow: hidden;
    position: relative;
    border-radius: 8px; /* Cantos arredondados */
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    margin-top: -10px;
}

.hero-image {
    width: 430px;
    height: 560px;
    object-fit: cover;
    display: block;
}

/* Seção de Contato e Estatísticas */
.contact-stats-section {
    display: flex;
    gap: var(--padding-base);
    padding: 60px 0;
    border-bottom: 1px solid var(--color-line);
}

.contact-box, .stats-box {
    flex: 1;
    background-color: var(--color-mid-dark);
    padding: 40px;
    border-radius: 12px;
    transition: transform 0.3s, box-shadow 0.3s;
}

.contact-box:hover, .stats-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4);
}

.contact-box h2 {
    font-size: 32px;
    margin: 15px 0;
    line-height: 1.2;
    font-weight: 700;
}

.contact-description {
    color: var(--color-text-mid);
    margin-bottom: 30px;
}

.contact-link {
    color: var(--color-accent);
    font-weight: 700;
    font-size: 18px;
    display: flex;
    align-items: center;
}

.contact-link i {
    margin-left: 10px;
    font-size: 28px;
    transition: transform 0.3s;
}

.contact-link:hover i {
    transform: translateX(5px);
}

.quote {
    font-size: 22px;
    font-weight: 500;
    font-style: italic;
    margin-bottom: 15px;
    border-left: 4px solid var(--color-accent);
    padding-left: 15px;
}

.quote-source {
    color: var(--color-text-mid);
    margin-bottom: 30px;
    font-size: 14px;
}

.stats-grid {
    display: flex;
    gap: 40px;
    flex-wrap: wrap;
}

.stat-item .number {
    display: block;
    font-size: 48px;
    font-weight: 800;
    color: var(--color-accent);
    line-height: 1;
}

.stat-item .label {
    display: block;
    color: var(--color-text-mid);
    font-size: 14px;
    margin-top: 5px;
    font-weight: 500;
}

/* Seção de Caixas de Serviços (Três caixas) */
#services.contact-stats-section {
    display: flex;
    flex-wrap: wrap; 
    gap: var(--padding-base);
    padding: 40px 0;
}

.service-box {
    flex: 1;
    min-width: 250px;
    background-color: var(--color-mid-dark);
    padding: 40px;
    border-radius: 12px;
    transition: background-color 0.3s, transform 0.3s;
}

.service-box:hover {
    background-color: #252530;
}

.accent-box {
    background-color: var(--color-accent);
    color: var(--color-dark-bg);
    transform: scale(1.05); /* Destaque sutil */
    box-shadow: 0 10px 20px rgba(0, 188, 212, 0.4);
}

.accent-box:hover {
    background-color: var(--color-accent);
    transform: scale(1.08);
}

.accent-box .service-title {
    color: var(--color-dark-bg);
}

.accent-box .projects-count {
    color: rgba(0, 0, 0, 0.7);
    font-weight: 600;
}

.service-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 10px;
}

.projects-count {
    font-size: 18px;
    color: var(--color-text-mid);
}

/* --- CARROSSEL GERAL E BOTÕES --- */

.carousel-wrapper {
    position: relative;
    width: 100%;
    margin: 20px auto;
    display: flex;
    align-items: center;
}

.carousel-container {
    flex-grow: 1;
    overflow: hidden;
}

.carousel {
    display: flex;
    align-items: center; 
    gap: 20px; 
    transition: transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94); 
    padding: 30px 0;
    /* NOVO: Dica de performance */
    will-change: transform;
}

/* NOVO: Dica de performance para os itens */
.carousel-item {
    will-change: width, height, transform, opacity, filter;
}

/* Estilos dos Botões de Navegação */
.nav-btn {
    background-color: var(--color-mid-dark);
    color: var(--color-accent);
    border: 2px solid var(--color-accent);
    padding: 18px;
    cursor: pointer;
    font-size: 24px;
    z-index: 10;
    line-height: 0;
    transition: background-color 0.3s, border-color 0.3s;
    border-radius: 50%;
    margin: 0 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
}

.nav-btn:hover {
    background-color: var(--color-accent);
    color: var(--color-dark-bg);
    box-shadow: 0 5px 15px rgba(0, 188, 212, 0.6);
}

/* --- SEÇÃO DE FOTOS (HORIZONTAL) --- */

.services-boxes-section {
    /* Este seletor foi criado no HTML para a seção de imagens */
    /* Garante que o H1 não seja afetado pelo flex-direction: column do responsivo */
}

.services-boxes-section h1 {
    width: 100%;
    font-size: 40px;
    margin-bottom: 20px;
    font-weight: 700;
}

.services-boxes-section .carousel-item {
    flex-shrink: 0; 
    width: calc(100% / 3); /* 3 itens visíveis */
    height: 400px; 
    position: relative;
    overflow: hidden; 
    border-radius: 12px; 
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
    transition: width 0.5s ease, height 0.5s ease, transform 0.5s ease, opacity 0.5s ease;
}

.services-boxes-section .carousel-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(100%) brightness(0.7); 
    transform: scale(0.9); 
    transition: transform 0.5s ease, filter 0.5s ease;
}

.services-boxes-section .carousel-item.active {
    width: calc(100% / 3 * 1.3); 
    height: 480px; 
    opacity: 1;
    z-index: 10;
    box-shadow: 0 15px 35px rgba(0, 188, 212, 0.4);
}

.services-boxes-section .carousel-item.active img {
    filter: grayscale(0%) brightness(1); 
    transform: scale(1); 
    object-fit: contain; /* Garante que a imagem inteira seja visível */
    background-color: var(--color-mid-dark); 
}

/* --- SEÇÃO DE VÍDEOS (VERTICAL) --- */

.video-carousel-section {
    padding: 80px 0;
    border-bottom: 1px solid var(--color-line);
}

.video-carousel-section h2 {
    font-size: 40px;
    margin-bottom: 20px;
    font-weight: 700;
}

.video-carousel-section .carousel-item {
    flex-shrink: 0; 
    width: calc(100% / 3 - 20px); /* 3 itens visíveis, considerando o gap */
    position: relative;
    overflow: hidden; 
    border-radius: 16px; 
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
    transition: transform 0.5s ease, box-shadow 0.5s ease;
    background-color: var(--color-mid-dark);
}

.video-content-wrapper {
    width: 100%;
    aspect-ratio: 9 / 16; /* Proporção 9:16 (vertical) */
    background-color: #000;
    border-radius: 12px; /* Arredonda a borda do vídeo */
    overflow: hidden; /* Garante que o iframe respeite a borda */
}

.video-carousel-section .carousel-item iframe {
    width: 100%;
    height: 100%;
    display: block;
    transform: scale(0.95);
    opacity: 0.7;
    transition: transform 0.5s ease, opacity 0.5s ease;
}

/* Estilo para o item ATIVO (centro) - Zoom e Foco */
.video-carousel-section .carousel-item.active {
    transform: scale(1.1); /* Item ativo aumenta de tamanho */
    z-index: 10;
    box-shadow: 0 15px 35px rgba(0, 188, 212, 0.6);
}

.video-carousel-section .carousel-item.active .video-content-wrapper {
     border: 4px solid var(--color-accent);
}

.video-carousel-section .carousel-item.active iframe {
    transform: scale(1); 
    opacity: 1; 
}

/* Informações do Vídeo Abaixo */
.video-info {
    padding: 15px 15px 20px;
    text-align: left;
}
.video-info h3 {
    font-size: 18px;
    font-weight: 600;
    color: var(--color-accent);
    margin-bottom: 5px;
}
.video-info p {
    font-size: 14px;
    color: var(--color-text-mid);
}

/* Botão Secundário para "Ver Mais" */
.btn-secondary {
    display: inline-flex; 
    align-items: center;
    background-color: transparent;
    border: 2px solid var(--color-accent);
    color: var(--color-accent);
    padding: 12px 25px;
    border-radius: 50px; 
    font-weight: 600;
    transition: background-color 0.3s, color 0.3s, transform 0.3s;
}

.btn-secondary:hover {
    background-color: var(--color-accent);
    color: var(--color-dark-bg);
    transform: translateY(-3px);
}

.btn-secondary i {
    margin-left: 10px;
    font-size: 20px;
}

/* --- RESPONSIVIDADE GERAL --- */

@media (max-width: 1024px) {
    /* Ajustes para Tablets */
    .hero-content {
        flex-direction: column;
        gap: 40px;
    }
    .intro {
        max-width: 100%;
    }
    .name {
        font-size: 72px;
    }
    .hero-image-container {
        max-width: 100%;
        height: 400px;
        clip-path: polygon(0% 0%, 100% 0%, 100% 100%, 0% 100%);
    }
    .contact-stats-section {
        flex-direction: column;
    }
    
    /* Ajuste para a seção de 3 caixas não ser afetada */
    #services.contact-stats-section {
        flex-direction: row; /* Mantém a direção em linha */
    }

    .service-box {
        min-width: 45%; 
    }
    .accent-box {
        transform: scale(1);
    }

    /* Carrossel de Fotos em Tablet (2 itens) */
    .services-boxes-section .carousel-item {
        width: calc(50% - 10px); 
        height: 350px;
    }
    .services-boxes-section .carousel-item.active {
        width: calc(50% * 1.15); 
        height: 400px;
    }
    
    /* Carrossel de Vídeos em Tablet (2 itens) */
    .video-carousel-section .carousel-item {
        width: calc(50% - 15px); 
    }
    .video-carousel-section .carousel-item.active {
        transform: scale(1.05); 
    }
}

@media (max-width: 600px) {
    /* Ajustes para Celular (Mobile First) */
    body {
        padding: 0 4vw; 
    }
    .navbar {
        display: none; 
    }
    .name {
        font-size: 50px;
    }
    .role-location {
        font-size: 18px;
    }
    .contact-box, .stats-box {
        padding: 30px 20px;
        min-width: 100%;
    }
    
    /* Ajuste para a seção de 3 caixas */
    #services.contact-stats-section {
        flex-direction: column; /* Agora sim, empilha em celular */
    }
    .service-box {
        padding: 30px 20px;
        min-width: 100%;
    }

    .contact-box h2 {
        font-size: 24px;
    }
    .services-boxes-section h1, .video-carousel-section h2 {
        font-size: 32px;
    }
    
    /* Carrossel de Fotos em Celular (1 item) */
    .services-boxes-section .carousel {
        gap: 10px;
        padding: 10px 0;
    }
    .services-boxes-section .carousel-item {
        width: 100%; /* Ajuste para mostrar 1 item por vez */
        height: 250px;
        box-shadow: none;
    }
    .services-boxes-section .carousel-item.active {
        width: 90%; /* Item ativo fica um pouco menor que o container */
        height: 300px;
        box-shadow: 0 10px 20px rgba(0, 188, 212, 0.4);
    }
    
    /* Carrossel de Vídeos em Celular (1 item) */
    .video-carousel-section .carousel-item {
        width: 75%; /* Item não-ativo tem 75% da largura */
        border-radius: 12px;
    }
    .video-carousel-section .carousel-item.active {
        transform: scale(1.05); /* Item ativo cresce um pouco */
    }

    .nav-btn {
        padding: 12px;
        font-size: 20px;
    }
}