/* Variáveis para cores */
:root {
    --background-color: #0d1117;
    --text-color: #c9d1d9;
    --link-color: #58a6ff;
    --header-bg-color: #161b22;
    --sidebar-bg-color: #161b22;
    --project-bg-color: #1a1a1a;
    --badge-bg-color: #1e2630;
    --badge-border-color: #30363d;
}

/* Reset básico e tipografia */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Roboto', sans-serif;
    color: var(--text-color);
}
body {
    background-color: var(--background-color);
    display: flex;
    font-size: 16px;
    line-height: 1.6;
    min-height: 100vh;
}

/* Estilos da Sidebar */
.sidebar {
    width: 280px;
    background-color: var(--sidebar-bg-color);
    padding: 2rem 1.5rem;
    position: fixed;
    height: 100vh;
    display: flex;
    flex-direction: column;
    z-index: 1000;
    transition: transform 0.3s ease-in-out;
    transform: translateX(0);
}
.sidebar.hidden {
    transform: translateX(-100%);
}
.sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}
.logo {
    font-family: 'Roboto Mono', monospace;
    font-weight: 700;
    font-size: 1.5rem;
}
.menu-toggle {
    display: none;
    font-size: 2rem;
    background: none;
    border: none;
    cursor: pointer;
}
.nav {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    flex-grow: 1;
}
.nav-link {
    font-family: 'Roboto Mono', monospace;
    font-size: 1rem;
    font-weight: 400;
    text-decoration: none;
    color: var(--text-color);
    transition: color 0.3s ease;
}
.nav-link:hover {
    color: var(--link-color);
}
.social-links {
    display: flex;
    justify-content: space-around;
    padding-top: 1rem;
    border-top: 1px solid var(--badge-border-color);
}
.social-links a {
    text-decoration: none;
}
.social-links svg {
    width: 24px;
    height: 24px;
    transition: transform 0.3s ease;
}
.social-links a:hover svg {
    transform: translateY(-3px);
    stroke: var(--link-color);
}

/* Estilos do Conteúdo Principal */
.main-content {
    flex-grow: 1;
    padding: 2rem;
    margin-left: 280px;
    transition: margin-left 0.3s ease-in-out;
}
.main-content.expanded {
    margin-left: 0;
}
section {
    max-width: 800px;
    margin: 0 auto 4rem;
    padding: 2rem;
}
.about-section {
    text-align: left;
}
.intro-title {
    font-family: 'Roboto Mono', monospace;
    font-size: 1rem;
    color: var(--link-color);
    margin-bottom: 0.5rem;
}
.name-title {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}
.tagline-title {
    font-size: 2rem;
    font-weight: 400;
    margin-bottom: 1.5rem;
    color: var(--text-color);
}
.about-section p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
}
.skills-title {
    font-family: 'Roboto Mono', monospace;
    font-size: 1.2rem;
    margin-bottom: 1rem;
}
.skills-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding-left: 0;
    list-style: none;
}
.skill-item {
    display: flex;
    align-items: center;
    background-color: var(--badge-bg-color);
    color: var(--text-color);
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    border: 1px solid var(--badge-border-color);
}
.skill-item i {
    color: #00f0ff;
    margin-right: 8px;
    font-size: 1.1rem;
}
.projects-section h2 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 2rem;
    text-align: center;
}

/* Correções de Layout para os Projetos */
.projects-grid {
    list-style: none;
    display: grid;
    gap: 2rem;
    /* Alinha os itens para terem a mesma altura */
    align-items: stretch;
    grid-template-columns: repeat(auto-fill, minmax(300px, 3fr));
}
.project-item {
    /* Define como Flexbox para que o conteúdo ocupe todo o espaço */
    display: flex;
    flex-direction: column;
    background-color: var(--project-bg-color);
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    /* Garante que o item ocupe a altura total do grid-row */
    height: 100%; 
}
.project-item:hover {
    transform: translateY(-5px);
}
.project-video {
    width: 100%;
    /* Mantém a proporção 16:9 do vídeo */
    aspect-ratio: 16/9;
    object-fit: cover;
    display: block;
}
.project-content {
    padding: 1.5rem;
    /* Define como Flexbox para empurrar o rodapé para baixo */
    display: flex;
    flex-direction: column;
    flex-grow: 1; /* Permite que o conteúdo cresça e preencha o espaço */
    justify-content: space-between; /* Empurra os elementos para as extremidades */
}
.project-content header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}
.project-icon svg {
    width: 40px;
    height: 40px;
    fill: var(--text-color);
}
.project-links {
    display: flex;
    gap: 10px;
}
.project-links a svg {
    width: 24px;
    height: 24px;
    stroke: var(--text-color);
    transition: stroke 0.3s ease;
}
.project-links a:hover svg {
    stroke: var(--link-color);
}
.project-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}
.project-description {
    font-size: 1rem;
    margin-bottom: 1rem;
}
.project-tech-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 0;
    list-style: none;
    /* Essa propriedade é a chave para empurrar a lista para o final */
    margin-top: auto; 
}
.project-tech-list li {
    font-family: 'Roboto Mono', monospace;
    font-size: 0.8rem;
    background-color: var(--badge-bg-color);
    padding: 5px 10px;
    border-radius: 20px;
    border: 1px solid var(--badge-border-color);
}

/* Estilos da Seção de Contato */
.contact-section {
    text-align: center;
}
.contact-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}
.contact-tagline {
    font-family: 'Roboto Mono', monospace;
    font-size: 1.2rem;
    color: var(--link-color);
    margin-bottom: 1.5rem;
}
.contact-section p {
    font-size: 1.1rem;
    line-height: 1.8;
}
.contact-info {
    font-family: 'Roboto Mono', monospace;
    margin-top: 2rem;
    font-size: 1.2rem;
}
.contact-info a {
    color: var(--link-color);
    text-decoration: none;
    transition: color 0.3s ease;
}
.contact-info a:hover {
    color: #fff;
    text-decoration: underline;
}

/* Media Queries para Responsividade */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        box-shadow: 2px 0 5px rgba(0, 0, 0, 0.5);
    }
    .sidebar.active {
        transform: translateX(0);
    }
    .main-content {
        margin-left: 0;
    }
    .menu-toggle {
        display: block;
        position: fixed;
        top: 20px;
        left: 20px;
        z-index: 1001;
        color: var(--text-color);
    }
}
