/* style.css */

/* Variáveis CSS para facilitar a manutenção */
:root {
    --primary-color: #007bff; /* Azul vibrante */
    --secondary-color: #6c757d; /* Cinza escuro */
    --accent-color: #ffc107; /* Amarelo para destaque */
    --text-color: #333;
    --light-bg: #f8f9fa; /* Fundo claro */
    --dark-bg: #343a40; /* Fundo escuro para header/footer */
    --border-color: #dee2e6;
    --font-family-base: 'Poppins', sans-serif;
}

/* Reset básico e estilos gerais */
body {
    font-family: var(--font-family-base);
    margin: 0;
    line-height: 1.6;
    color: var(--text-color);
    background-color: #fff;
    scroll-behavior: smooth; /* Rolagem suave para âncoras */
}

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

.section-padding {
    padding: 80px 0;
}

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

h1, h2, h3 {
    font-weight: 700;
    color: var(--text-color);
    margin-top: 0;
    margin-bottom: 20px;
}

h2 {
    text-align: center;
    font-size: 2.8rem;
    margin-bottom: 60px;
    position: relative;
    padding-bottom: 10px;
}

h2::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

p {
    margin-bottom: 15px;
}

/* Botões */
.button {
    display: inline-block;
    padding: 12px 25px;
    text-decoration: none;
    border-radius: 50px; /* Borda arredondada */
    font-weight: 600;
    transition: all 0.3s ease;
    text-align: center;
    border: none;
    cursor: pointer;
}

.primary-button {
    background-color: var(--primary-color);
    color: #fff;
}

.primary-button:hover {
    background-color: #0056b3;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 123, 255, 0.3);
}

.secondary-button {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    margin-left: 15px;
}

.secondary-button:hover {
    background-color: var(--primary-color);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 123, 255, 0.3);
}

.small-button {
    padding: 8px 15px;
    font-size: 0.9rem;
    margin: 0 5px;
}

.github-button {
    background-color: #212529;
    color: #fff;
}

.github-button:hover {
    background-color: #000;
}


/* Header */
header {
    background-color: var(--dark-bg);
    color: #fff;
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
}

header .logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: #fff;
}

header nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
}

header nav ul li {
    margin-left: 30px;
}

header nav ul li a {
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    padding: 5px 0;
    position: relative;
    transition: color 0.3s ease;
}

header nav ul li a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -5px;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

header nav ul li a:hover {
    color: var(--primary-color);
}

header nav ul li a:hover::after,
header nav ul li a.active::after { /* Opcional: para indicar seção ativa com JS */
    width: 100%;
}


/* Hero Section */
.hero {
    background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)), url('https://via.placeholder.com/1500x800/222222/FFFFFF?text=Fundo+de+Capa') no-repeat center center/cover;
    color: #fff;
    text-align: center;
    padding: 150px 0;
    min-height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-content h1 {
    font-size: 4.5rem;
    margin-bottom: 15px;
    color: #fff;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.hero-content p {
    font-size: 1.8rem;
    margin-bottom: 40px;
    color: rgba(255,255,255,0.9);
}

.hero-content .button {
    margin: 0 10px;
}

/* About Section */
.about-content {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 40px;
    padding: 0 20px;
}

.profile-pic {
    width: 280px;
    height: 280px;
    border-radius: 50%;
    object-fit: cover;
    border: 6px solid var(--primary-color);
    box-shadow: 0 8px 15px rgba(0,0,0,0.1);
    flex-shrink: 0; /* Não encolher a imagem */
}

.about-text {
    flex: 1;
    min-width: 300px; /* Garante que o texto tenha um tamanho mínimo antes de quebrar */
    font-size: 1.15rem;
    line-height: 1.8;
}

/* Projects Section */
.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
    padding: 0 20px;
}

.project-card {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.project-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 25px rgba(0,0,0,0.15);
}

.project-card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
}

.project-card h3 {
    padding: 15px 20px 0;
    margin: 0;
    font-size: 1.8rem;
    color: var(--primary-color);
}

.project-card p {
    padding: 0 20px 15px;
    font-size: 1rem;
    flex-grow: 1; /* Permite que o parágrafo ocupe o espaço restante */
}

.project-links {
    padding: 15px 20px 20px;
    display: flex;
    justify-content: flex-start;
    gap: 10px;
    margin-top: auto; /* Empurra os links para o final do card */
}

/* Skills Section */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
    padding: 0 20px;
}

.skill-item {
    background-color: var(--primary-color);
    color: #fff;
    padding: 15px 20px;
    border-radius: 8px;
    text-align: center;
    font-weight: 600;
    font-size: 1.1rem;
    box-shadow: 0 4px 10px rgba(0, 123, 255, 0.2);
    transition: transform 0.3s ease, background-color 0.3s ease;
}

.skill-item:hover {
    transform: translateY(-5px);
    background-color: #0056b3;
}

/* Contact Section */
.contact-intro {
    text-align: center;
    font-size: 1.1rem;
    margin-bottom: 40px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 20px;
}

.contact-form {
    max-width: 600px;
    margin: auto;
    display: flex;
    flex-direction: column;
    gap: 20px;
    background: #fff;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
}

.contact-form input,
.contact-form textarea {
    padding: 15px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    width: 100%;
    box-sizing: border-box; /* Garante que padding e border não aumentem a largura */
    font-family: var(--font-family-base);
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.25);
}

.contact-form button {
    align-self: flex-start; /* Alinha o botão à esquerda dentro do formulário */
    margin-top: 10px;
}

.social-links {
    text-align: center;
    margin-top: 50px;
    padding: 0 20px;
}

.social-icon {
    display: inline-block;
    margin: 0 15px;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: color 0.3s ease, transform 0.3s ease;
}

.social-icon:hover {
    color: #0056b3;
    transform: translateY(-3px);
}


/* Footer */
footer {
    background-color: var(--dark-bg);
    color: #fff;
    text-align: center;
    padding: 30px 0;
    margin-top: 0; /* Remove a margem superior que tinha no modelo anterior */
    font-size: 0.9rem;
}

/* Media Queries para Responsividade */
@media (max-width: 992px) {
    .hero-content h1 {
        font-size: 3.5rem;
    }

    .hero-content p {
        font-size: 1.5rem;
    }

    h2 {
        font-size: 2.2rem;
    }

    .about-content {
        flex-direction: column;
        text-align: center;
    }

    .profile-pic {
        margin-bottom: 25px;
    }

    .about-text, .contact-intro {
        padding: 0 10px;
    }
}

@media (max-width: 768px) {
    header .container {
        flex-direction: column;
        padding: 10px 20px;
    }

    header nav ul {
        margin-top: 15px;
        flex-wrap: wrap;
        justify-content: center;
    }

    header nav ul li {
        margin: 5px 15px;
    }

    .hero {
        padding: 100px 0;
    }

    .hero-content h1 {
        font-size: 2.8rem;
    }

    .hero-content p {
        font-size: 1.3rem;
    }

    .hero-content .button {
        display: block;
        margin: 15px auto;
        width: 80%;
        max-width: 250px;
    }

    .secondary-button {
        margin-left: 0;
    }

    .section-padding {
        padding: 60px 0;
    }

    h2 {
        font-size: 2rem;
        margin-bottom: 40px;
    }

    .project-grid, .skills-grid {
        grid-template-columns: 1fr; /* Uma coluna em telas pequenas */
        padding: 0 15px;
    }

    .project-links {
        justify-content: center;
    }

    .contact-form {
        padding: 20px;
    }

    .social-links {
        margin-top: 30px;
    }

    .social-icon {
        margin: 0 10px;
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .hero-content h1 {
        font-size: 2.2rem;
    }
    .hero-content p {
        font-size: 1rem;
    }
    .profile-pic {
        width: 200px;
        height: 200px;
    }
    .skill-item {
        font-size: 1rem;
        padding: 12px 15px;
    }
}
