/* --- Resete --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Courier New', Courier, monospace;
    line-height: 1.6;
}

/* --- Body --- */
body {  
    display: flex;
    flex-direction: column;
    width: 100vw;
    min-height: 100vh;
    margin: auto;
    color: rgb(200, 187, 187);
    background-image: radial-gradient(
        circle at center,
        rgba(255, 255, 255, 0.2) 0%,
        transparent 70%
    ),
    url("../img/bg1.jpg");
    overflow-x: hidden; /* Evita barras de rolagem horizontais indesejadas */
}

/* --- Tag "a" estilizada --- */
.nav-item a {
    text-decoration: none;
    color: white;
}
.nav-item a:hover {
    color: rgba(255, 255, 255, 0.708);
}

/* --- Header --- */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: black;
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.207);
}
.nav-bar {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 1.5rem 3rem;
}

.logo {
    display: flex;
    align-items: center;
    height: 100%; 
}

.logo img {
    height: 50px; /* CORRIGIDO: estava '50x' */
    width: auto; 
    max-height: 80px; 
    display: block;
}
.nav-list ul {
    list-style: none;
    display: flex; 
    gap: 10px;
}
.nav-list ul li {
    font-size: 1.4rem;
    font-weight: 500;
    margin-left: 1.5rem;
    letter-spacing: 1px;
    cursor: pointer;
    transition: 0.3s ease;
}
.nav-item {
    position: relative; 
    cursor: pointer;
    padding: 1px 0;
}

/* --- Barra de evento --- */
.nav-item::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 2px;
    background-color: rgb(175, 172, 191); 
    transform: scaleX(0);         
    transform-origin: left;        
    transition: transform 0.3s ease;
}
.nav-item:hover::after {
    transform: scaleX(1); 
}

/* -- Current-Page-- */
.nav-item[current-page], 
.nav-item[current-page] a {
    pointer-events: none; 
    cursor: default;      
}
.nav-item[current-page]::after {
    display: none;
}
.nav-item[current-page] a {
    color: rgba(255, 255, 255, 0.708); 
}

.mobile-menu-icon {
    cursor: pointer;
    display: none;
} 
.mobile-menu {
    display: none;
}

@media(max-width:720px) {
    .nav-list {
        display: none;
    }
    .mobile-menu-icon {
        display: block;
    } 

    .mobile-menu.open {
        display: block;
        position: fixed;          
        top: 110px; /* AJUSTADO proporcionalmente à nova altura da sua logo corrigida */
        left: 0;
        width: 100%;
        height: calc(100vh - 110px); 
        background-color: rgba(0, 0, 0, 0.95); 
        z-index: 1001;            
        overflow-y: auto;         
    }

    .mobile-menu ul {
        display: flex;
        flex-direction: column; 
        align-items: center;
        padding: 2rem 0;
    }
    .mobile-menu .nav-item {
        margin: 1rem 0;
        list-style: none;
        font-size: 1.5rem;
    }
}

@media(max-width:450px) {
    .container .page-home {
        display: flex;
        flex-direction: column;
        gap: 1rem;
    }
}

main {
    width: 100%;
    margin-top: 7rem;
}

/* AFINAÇÃO 1: Centralizar o conteúdo e limitar a largura em telas grandes */
.section {
    width: 100%;
    max-width: 1100px;        /* Define um limite confortável para o conteúdo não espalhar no monitor */
    margin: 0 auto;           /* Centraliza perfeitamente o bloco na tela */
    min-height: 100vh;
    padding: 8rem 4rem 4rem;  /* Aumentei levemente a margem dos lados (de 3rem para 4rem) */
}

html {
    scroll-behavior: smooth;
}

/* H O M E */
/* Container que junta o texto e a foto */
.page-home {
    display: flex;
    flex-direction: column-reverse; 
    align-items: center;
    justify-content: space-between;
    gap: 100px; 
    padding: 20px 0 60px; /* AFINAÇÃO 2: Reduzi o padding superior de 60px para 20px para subir o conteúdo */
}

/* Caixa do texto */
.home-content {
    text-align: center; 
    max-width: 600px;
}

.home-content h1 {
    font-size: 2.5rem;
    color: #ffffff; 
    margin: 10px 0;
}

.home-content h3 {
    font-size: 1.2rem;
    font-weight: 400;
    line-height: 1.6;
    color: #cccccc;
}

/* Caixa da Foto */
.home-picture .foto {
    width: 280px;
    height: 280px;
    background-color: #333; 
    border-radius: 50%; 
    display: flex;
    align-items: center;
    justify-content: center;
    border: 3px solid #00ff00; 
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
}

/* --- RESPONSIVIDADE (Telas maiores como Computadores) --- */
@media (min-width: 768px) {
    .page-home {
        flex-direction: row; 
        text-align: left;
        min-height: 70vh; /* AFINAÇÃO 2: Reduzi de 80vh para 70vh. Isso faz a seção ocupar menos espaço vertical, puxando o conteúdo para cima */
    }

    .home-content {
        text-align: left; 
    }

    .home-picture .foto {
        width: 350px;
        height: 350px;
    }
}

/* --- C O N T A T O --- */
.contato-container {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.contato-container h2 {
    font-size: 2.2rem;
    color: white;
    margin-bottom: 2rem;
    letter-spacing: 2px;
}

.contato-texto {
    font-size: 1.2rem;
    color: #cccccc;
    margin-bottom: 3rem;
    text-align: center !important; /* Sobrescreve o justify padrão para centralizar o convite */
}

/* Container dos botões */
.contato-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap; /* Faz quebrar linha no celular se não couber */
    gap: 20px;
    padding-top: 5rem;
}

/* Estilização dos Botões de Contato */
.btn-contato {
    text-decoration: none;
    color: white;
    font-size: 1.2rem;
    font-weight: bold;
    padding: 12px 30px;
    border: 2px solid green; /* Borda verde combinando com seu rodapé/foto */
    border-radius: 5px;
    background-color: transparent;
    transition: all 0.3s ease;
    cursor: pointer;
}

/* Efeito de passar o mouse nos botões */
.btn-contato:hover {
    background-color: green;
    color: black; /* Inverte a cor do texto para dar destaque */
    box-shadow: 0 0 15px rgba(0, 255, 0, 0.4); /* Leve brilho neon verde */
    transform: translateY(-3px); /* Faz o botão subir de leve */
}

/* Ajuste mobile para os botões */
@media (max-width: 480px) {
    .contato-links {
        flex-direction: column;
        width: 100%;
    }
    .btn-contato {
        width: 100%;
        text-align: center;
    }
}


/* --- P R O J E T O S --- */
.projetos-container h2 {
    font-size: 2.2rem;
    color: white;
    margin-bottom: 2rem;
    letter-spacing: 2px;
}

/* Cria a malha de cards: 1 coluna no celular, 2 ou mais no PC automaticamente */
.projetos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    width: 100%;
}

/* Estilo do Card Individual */
.projeto-card {
    background-color: rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 25px;
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* Garante que os botões fiquem sempre alinhados embaixo */
    transition: all 0.3s ease;
}

/* Efeito ao passar o mouse no card */
.projeto-card:hover {
    border-color: #00ff00; /* Borda acende em verde */
    transform: translateY(-5px); /* Efeito flutuante */
    box-shadow: 0 5px 15px rgba(0, 255, 0, 0.1);
}

.projeto-info h3 {
    font-size: 1.5rem;
    color: white;
    margin-bottom: 1rem;
    text-align: center !important; /* FORÇA a centralização do título */
}

.projeto-info p {
    font-size: 1rem;
    color: #cccccc;
    margin-bottom: 1.5rem;
    text-align: justify;
}

/* Tags de Tecnologias dentro do Card */
.projeto-techs {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 2rem;
}

.projeto-techs span {
    font-size: 0.85rem;
    background-color: rgba(255, 255, 255, 0.1);
    color: #00ff00; /* Texto das tags em verde terminal */
    padding: 4px 10px;
    border-radius: 4px;
    font-weight: bold;
}

/* Área dos botões de ação */
.projeto-botoes {
    display: flex;
    gap: 15px;
}

.btn-projeto {
    flex: 1; /* Faz os botões dividirem o espaço igualmente */
    text-decoration: none;
    text-align: center;
    color: black;
    background-color: #00ff00;
    font-weight: bold;
    padding: 10px;
    border-radius: 5px;
    font-size: 1rem;
    border: 1px solid #00ff00;
    transition: all 0.3s ease;
}

.btn-projeto:hover {
    background-color: transparent;
    color: #00ff00;
}

/* Variação de botão vazado caso queira dois botões no mesmo card */
.btn-projeto-vazado {
    background-color: transparent;
    color: white;
    border-color: rgba(255, 255, 255, 0.3);
}

.btn-projeto-vazado:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: white;
    border-color: white;
}


/* F O O T E R */
footer {   
    display: flex;
    justify-content: space-around;
    background-color: green;
    margin: 0 3rem; 
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
}

/* A J U S T E S  F I N O S */
section[id] {
    scroll-margin-top: 80px; 
}

.section p {
    text-align: justify;
}

.section h3{
    text-align: justify;
}


/* F O T O  D E  C A P A */
.home-picture {
    width: 100%;
    max-width: 350px;      /* Define o tamanho máximo desejado em telas grandes */
    aspect-ratio: 1 / 1;   /* Força a caixa a ser sempre um quadrado perfeito */
    border-radius: 50%;    /* Garante o formato perfeitamente circular */
    overflow: hidden;
    margin: 0 auto;        /* Centraliza a imagem no contêiner pai */
}

.home-picture img {
    width: 100%;
    height: 100%;
    object-fit: cover;     /* Impede que a foto seja esticada ou deformada */
    display: block;
}

/* A J U S T E  F I N O */
.skills-container {
    display: flex;
    justify-content: space-around;
}
@media (max-width: 770px) {
    .skills-container {
        display: flex;
        flex-direction: column;
        gap: 1rem;
        width: 100%;
    }
}