/* --- CONFIGURAÇÕES GERAIS --- */
body {
    background-color: #0f172a;
    color: #f1f5f9;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    overflow-x: hidden;
    scroll-behavior: smooth;
    display: flex;
    justify-content: center;
}

.container {
    max-width: 900px;
    width: 90%;
    margin: 10px auto;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* --- CABEÇALHO --- */
header {
    width: 100%;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 120px;
    margin-bottom: 20px;
}

.avatar {
    position: absolute;
    left: 0;
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border: 3px solid #38bdf8;
}

.header-text {
    text-align: center;
    width: 100%;
    margin-top: 35px;
}

.header-text h1 {
    margin: 0;
    font-size: 2.2rem;
    color: #38bdf8;
}

.tagline {
    color: #94a3b8;
    font-size: 1.0rem;
    min-height: 1.2em;
    margin-top: 5px;
}

/* Badge de Visitante - FIXO E MODERNO */
#visitante-info {
    position: fixed;
    top: 20px;
    right: 20px;
    background: rgba(30, 41, 59, 0.85);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.8rem;
    color: #38bdf8;
    border: 1px solid #38bdf8;
    z-index: 1000;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(5px);
}

/* --- SEÇÕES --- */
.sobre,
.projetos,
.habilidades,
.contato {
    text-align: center;
    margin-bottom: 50px;
    width: 100%;
}

.sobre h2,
.habilidades h2,
.contato h2 {
    color: #ffffff;
    font-size: 1.2rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 15px;
}

/* --- CARDS DE PROJETOS --- */
.projetos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    width: 100%;
}

.card {
    background: rgba(30, 41, 59, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 25px;
    border-radius: 16px;
    transition: 0.3s;
}

.card:hover {
    border-color: #38bdf8;
    transform: translateY(-5px);
}

.card i {
    font-size: 2.5rem;
    color: #38bdf8;
    margin-bottom: 15px;
}

.card h3 {
    color: #ffffff;
    margin: 10px 0;
}

.status {
    display: inline-block;
    font-size: 0.75rem;
    background: #0ea5e9;
    padding: 5px 12px;
    border-radius: 15px;
    margin-top: 15px;
}

/* --- HABILIDADES COLORIDAS --- */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    gap: 15px;
}

.skill-item {
    background: rgba(30, 41, 59, 0.5);
    padding: 15px 10px;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: 0.3s;
}

.skill-item:hover i {
    color: #ffffff !important;
}

/* Cores Hover Habilidades */
.skill-item.python:hover {
    border-color: #38bdf8;
    background: rgba(56, 189, 248, 0.1);
}

.skill-item.node:hover {
    border-color: #68a063;
    background: rgba(104, 160, 99, 0.1);
}

.skill-item.html:hover {
    border-color: #e34f26;
    background: rgba(227, 79, 38, 0.1);
}

.skill-item.js:hover {
    border-color: #f7df1e;
    background: rgba(247, 223, 30, 0.1);
}

.skill-item.git:hover {
    border-color: #f05032;
    background: rgba(240, 80, 50, 0.1);
}

.skill-item.docker:hover {
    border-color: #2496ed;
    background: rgba(36, 150, 237, 0.1);
}

.skill-item.linux:hover {
    border-color: #f1f5f9;
    background: rgba(241, 245, 249, 0.1);
}

.skill-item.vscode:hover {
    border-color: #007acc;
    background: rgba(0, 122, 204, 0.1);
}

.skill-item i {
    font-size: 2.0rem;
    transition: 0.3s;
}

.python i {
    color: #38bdf8;
}

.node i {
    color: #68a063;
}

.html i {
    color: #e34f26;
}

.js i {
    color: #f7df1e;
}

.git i {
    color: #f05032;
}

.docker i {
    color: #2496ed;
}

.linux i {
    color: #f1f5f9;
}

.vscode i {
    color: #007acc;
}

/* --- BOTÕES E RODAPÉ --- */
.contato-opcoes {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

.btn-contato {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: bold;
    text-decoration: none;
    font-size: 0.9rem;
}

.whatsapp {
    background: #25d366;
    color: white;
}

.email {
    background: #38bdf8;
    color: #0f172a;
}

footer {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 20px 0;
    width: 100%;
    text-align: center;
}

.social-title {
    color: #94a3b8;
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 20px;
    font-size: 1.2rem;
}

.social-links a {
    color: #94a3b8;
    text-decoration: none;
    transition: 0.3s;
}

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

#backToTop {
    position: fixed;
    bottom: 30px;
    right: 30px;
    display: none;
    background: #38bdf8;
    color: #0f172a;
    border: none;
    padding: 15px;
    border-radius: 50%;
    cursor: pointer;
}

/* --- AJUSTE MOBILE CORRECTION (HARMONIZADO) --- */
/* --- AJUSTE MOBILE: CORREÇÃO DEFINITIVA --- */
@media screen and (max-width: 768px) {

    /* 1. Ajusta o Badge de Visitante */
    #visitante-info {
        top: 10px !important;
        right: 10px !important;
        padding: 4px 10px !important;
        font-size: 0.7rem !important;
        background: rgba(30, 41, 59, 0.95) !important;
    }

    /* 2. Reseta o Header para empilhar */
    header {
        flex-direction: column !important;
        min-height: auto !important;
        padding-top: 60px !important;
        /* Espaço para o visitante não cobrir o boneco */
        margin-bottom: 20px !important;
        position: relative !important;
    }

    /* 3. Tira o boneco do "Absolute" e centraliza */
    .avatar {
        position: static !important;
        /* ISSO AQUI É A CHAVE: cancela o left: 0 */
        width: 90px !important;
        height: 90px !important;
        margin: 0 auto 15px auto !important;
        display: block !important;
    }

    /* 4. Ajusta o texto */
    .header-text {
        margin-top: 0 !important;
        text-align: center !important;
    }

    .header-text h1 {
        font-size: 1.8rem !important;
    }
}