/* 1. CONFIGURAÇÕES GERAIS E O MODO DARK  */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Poppins", sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: #0f172a;
    color: #f1f5f9;
    line-height: 1.6;
    overflow-x: hidden;
}


/* 2. SEÇÕES GERAIS */

section {
    display: block;
    width: 100%;
    margin: 0 auto;
    padding: 80px 0;
    position: relative;
    min-height: 100vh;
    background-color: #0f172a;
    scroll-margin-top: 70px;
}

.section-content {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

.section-title {
    margin-bottom: 25px;
}


/* 3. ANIMAÇÃO */

.fade-in {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeUp 0.6s ease forwards;
}

@keyframes fadeUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 4. NAVBAR */

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 5%;
    background-color: #1e293b;
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid #334155;
}

.logo {
    font-weight: bold;
    font-size: 1.4rem;
    color: #38bdf8;
}

.nav-links {
    display: flex;
    list-style: none;
}

.nav-links li {
    margin-left: 25px;
}

.nav-links a {
    color: #e2e8f0;
    text-decoration: none;
    position: relative;
    transition: 0.3s;
}

.nav-links a:hover {
    color: #38bdf8;
}

.nav-links a::after {
    content: "";
    position: absolute;
    width: 0%;
    height: 2px;
    background: #38bdf8;
    left: 0;
    bottom: -5px;
    transition: 0.3s;
}

.nav-links a:hover::after {
    width: 100%;
}

/* 5. SOBRE */

.sidebar {
    width: 100%;    
    background: linear-gradient(180deg, #1e293b, #0f172a);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 60px 0;
    margin-bottom: 0;

    position: relative;
    z-index: 1;
}

.avatar {
    width: 180px;
    height: 180px;
    display: block;
    margin: 0 auto 20px auto;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid #38bdf8;
    box-shadow: 0 10px 30px rgba(0,0,0,0.4);
}

.bio {
    max-width: 600px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.bio h1 {
    font-size: 2.3rem;
    margin-bottom: 10px;
}

.bio p {
    color: #94a3b8;
    font-size: 1.1rem;
}

/* 6. BOTÕES DOS LINKS */

.social-links {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 20px auto 0 auto;
    width: 200px;
}

.btn {
    padding: 12px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: 0.3s;
    text-align: center;
}

.linkedin {
    background-color: #0077b5;
    color: white;
    border: 1px solid #005582;
}

.github {
    background-color: #24292e;
    color: white;
    border: 1px solid #334155;
}

.btn:hover {
    transform: translateY(-3px);
    opacity: 0.9;
}

/* 7. PROJETOS */

.content {
    background: #0f172a;
}

.section-title {
    text-align: center;
    font-size: 2.4rem;
    font-weight: 700;
    margin-bottom: 40px;
    color: #f1f5f9;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    grid-template-rows: auto; 
    gap: 25px;
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
    justify-content: center;
    align-items: stretch;
    margin-bottom: 40px;
}


#projetos {
    padding-top: 40px;
    padding-bottom: 120px;
}

#projetos .projects-grid {
    margin-bottom: 0;
}

/* 8. CARDS */

.card {
    background: #020617;
    border-radius: 12px;
    border: 1px solid #334155;
    display: flex;
    flex-direction: column;
    transition: 0.3s;
    text-align: left;
    width: 100%;
    max-width: 350px;
    overflow: hidden;
    position: relative;
}


.card:hover {
    transform: translateY(-8px);
    border-color: #38bdf8;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.5);
}

.card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, transparent, rgba(56,189,248,0.2), transparent);
    opacity: 0;
    transition: 0.5s;
    pointer-events: none;
}

.card:hover::before {
    opacity: 1;
}

.card-content {
    padding: 25px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.card-content h3 {
    color: #38bdf8;
    margin-bottom: 20px;
    font-size: 1.3rem;
    flex-grow: 0;
}

.card-content p {
    color: #94a3b8;
    margin-bottom: 20px;
    font-size: 0.95rem;
    flex-grow: 1;
}

.link-projeto {
    color: #38bdf8;
    text-decoration: none;
    font-weight: bold;
    margin-top: auto;
}

/* 9. CONTATO */

#contato {
    background-color: #020617;
    border-top: 1px solid #1e293b;
    padding: 102px 20px;
    width: 100%;
    display: flex;
    justify-content: center;
}

.contact-container {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.btn-email {
    display: inline-block;
    background-color: #10b981;
    color: white;
    padding: 16px 45px;
    border-radius: 50px;
    font-weight: bold;
    text-decoration: none;
    margin-top: 25px;
    transition: 0.3s;
}

.btn-email:hover {
    background-color: #059669;
    transform: scale(1.05);
}

/* 10. FOOTER - FINAL DA TELA */

footer {
    text-align: center;
    padding: 40px 20px;
    background-color: #020617;
    border-top: 1px solid #334155;
    color: #64748b;
    font-size: 0.85rem;
}

/* 11. CARÁTER RESPONSIVO - TELAS MENORES */

@media (max-width: 900px) {
    .nav-links {
        display: none;
    }

    section {
        padding: 100px 20px;
    }
}

@media (min-width: 768px) {
    .social-links {
        flex-direction: row;
        justify-content: center;
    }
}