/* ==========================================================================
   1. CONFIGURAÇÕES GERAIS E VARIÁVEIS
   ========================================================================== */
:root {
    /* Paleta de Cores (Dark Theme) */
    --bg-dark: #0a0a0a;
    --bg-darker: #050505;
    --card-bg: #161616;
    
    /* Cores de Destaque (IFSP Brand + Tech) */
    --primary: #2ecc71;  /* Verde vibrante */
    --secondary: #e74c3c; /* Vermelho IFSP */
    --accent: #3498db;   /* Azul Tech */
    
    /* Texto */
    --text-main: #ffffff;
    --text-muted: #a0a0a0;
    
    /* Efeitos */
    --glass: rgba(20, 20, 20, 0.7);
    --neon-glow: 0 0 10px rgba(46, 204, 113, 0.5);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    
    /* Fontes */
    --font-code: 'Fira Code', monospace;
    --font-body: 'Inter', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth; /* Rolagem suave ao clicar nos links */
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden; /* Evita rolagem horizontal indesejada */
}

/* Canvas de fundo (Partículas) */
#bg-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1; /* Fica atrás de tudo */
    opacity: 0.3;
}

/* ==========================================================================
   2. NAVBAR (GLASS EFFECT)
   ========================================================================== */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 1rem 5%;
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: var(--transition);
}

.glass-effect {
    background: var(--glass);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

/* Logo Area */
.logo-area {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo-img {
    height: 45px;
    width: auto;
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.logo-title {
    font-family: var(--font-code);
    font-weight: 700;
    font-size: 1.2rem;
    letter-spacing: -0.5px;
}

.logo-subtitle {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.highlight {
    color: var(--primary);
}

/* Links de Navegação */
.nav-links {
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav-item {
    color: var(--text-main);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    position: relative;
    transition: var(--transition);
}

.nav-item:not(.btn-demandante)::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0%;
    height: 2px;
    background-color: var(--primary);
    transition: var(--transition);
}

.nav-item:not(.btn-demandante):hover::after {
    width: 100%;
}

.nav-item:hover {
    color: var(--primary);
}

/* Botão Demandante na Navbar */
.btn-demandante {
    background: rgba(46, 204, 113, 0.1);
    color: var(--primary);
    padding: 8px 16px;
    border-radius: 4px;
    border: 1px solid var(--primary);
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-code);
    font-size: 0.85rem;
}

.btn-demandante:hover {
    background: var(--primary);
    color: #000; /* Texto preto para contraste no hover */
    box-shadow: var(--neon-glow);
}

.mobile-menu-btn {
    display: none; /* Escondido no desktop */
    font-size: 1.5rem;
    cursor: pointer;
}

/* ==========================================================================
   3. HERO SECTION (APRESENTAÇÃO)
   ========================================================================== */
.hero-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 5%;
    position: relative;
    overflow: hidden;
}

.hero-content {
    max-width: 600px;
    z-index: 2;
}

.badge-container {
    margin-bottom: 20px;
}

.status-badge {
    background: rgba(255, 255, 255, 0.05);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    color: var(--primary);
    border: 1px solid rgba(46, 204, 113, 0.2);
    font-family: var(--font-code);
}

/* Título com Efeito de Digitação */
h1#typing-title {
    font-size: clamp(2rem, 5vw, 3.5rem); /* Tamanho responsivo */
    line-height: 1.1;
    margin-bottom: 20px;
    font-weight: 800;
    min-height: 3.5rem; /* Evita pulo de layout */
}

.cursor {
    display: inline-block;
    width: 10px;
    height: 1em; /* Altura relativa ao texto */
    background-color: var(--primary);
    margin-left: 5px;
    animation: blink 1s infinite;
    vertical-align: middle; /* Alinha com o texto */
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

.hero-description {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 30px;
    max-width: 480px;
}

/* Botões do Hero */
.hero-actions {
    display: flex;
    gap: 15px;
}

.btn-primary, .btn-secondary {
    padding: 12px 24px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-primary {
    background-color: var(--primary);
    color: #000;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--neon-glow);
}

.btn-secondary {
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--text-main);
}

.btn-secondary:hover {
    border-color: var(--text-main);
    background: rgba(255, 255, 255, 0.05);
}

/* Visual Hero (Janela de Código) */
.hero-visual {
    position: absolute;
    right: 5%;
    width: 45%;
    max-width: 500px;
    z-index: 1;
}

.code-window {
    background: #1e1e1e;
    border-radius: 8px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
    overflow: hidden;
}

.window-header {
    background: #252526;
    padding: 10px 15px;
    display: flex;
    gap: 8px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}
.red { background: #ff5f56; }
.yellow { background: #ffbd2e; }
.green { background: #27c93f; }

.window-body {
    padding: 20px;
    font-family: var(--font-code);
    font-size: 0.9rem;
    color: #d4d4d4; /* Cor padrão VS Code */
}

.code-comment { color: #6a9955; }
.code-keyword { color: #569cd6; }
.code-string { color: #ce9178; }
.code-func { color: #dcdcaa; }

/* ==========================================================================
   4. SEÇÕES E GRIDS
   ========================================================================== */
.section-padding {
    padding: 80px 5%;
}

.bg-darker {
    background-color: var(--bg-darker);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

.section-heading {
    font-size: 2rem;
    margin-bottom: 50px;
    position: relative;
    display: inline-block;
    font-family: var(--font-code);
}

.section-heading::after {
    content: '';
    position: absolute;
    width: 40px;
    height: 4px;
    background: var(--primary);
    bottom: -10px;
    left: 0;
}

.blink {
    animation: blink 1s step-end infinite;
    color: var(--primary); /* Garante que o cursor seja verde */
    font-weight: bold;
}

/* Caso a animação blink não esteja definida ainda, garanta que ela exista: */
@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

/* Grid Sobre */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.quote-box {
    margin-top: 20px;
    border-left: 3px solid var(--primary);
    padding-left: 20px;
    font-style: italic;
    color: var(--text-muted);
}

.about-image-wrapper {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
}

.group-photo {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.5s ease;
}

.about-image-wrapper:hover .group-photo {
    transform: scale(1.05);
}

/* Grids Dinâmicos (Tecnologia e Equipe) */
.tech-grid, .members-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); 
    gap: 20px;
    justify-content: center; /* Centraliza se sobrarem espaços */
}

/* Cards Genéricos */
.tech-card, .member-card {
    background: var(--card-bg);
    padding: 25px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: var(--transition);
}

.tech-card:hover, .member-card:hover {
    transform: translateY(-10px);
    border-color: var(--primary);
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

/* Estilo Específico Tech Card */
.tech-icon {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 15px;
}

.tech-title {
    font-size: 1.2rem;
    margin-bottom: 10px;
    font-weight: 600;
}

.tech-desc {
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* Estilo Específico Equipe */
.member-avatar {
    width: 70px; /* Reduzi um pouquinho */
    height: 70px;
    border-radius: 50%;
    margin-bottom: 10px;
    border: 2px solid var(--primary);
    padding: 2px;
    background-clip: content-box;
    object-fit: cover; /* A correção que fizemos antes */
}

.member-role {
    font-size: 0.8rem;
    color: var(--primary);
    font-family: var(--font-code);
    margin-bottom: 10px;
    display: block;
}

/* ==========================================================================
   5. FOOTER
   ========================================================================== */
footer {
    background: #000;
    padding: 40px 5%;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.footer-logo span {
    font-family: var(--font-code);
    color: var(--primary);
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    color: var(--text-main);
    font-size: 1.5rem;
    transition: var(--transition);
}

.social-links a:hover {
    color: var(--primary);
}

/* ==========================================================================
   6. RESPONSIVIDADE (MOBILE)
   ========================================================================== */
@media (max-width: 768px) {
    .nav-links {
        display: none; /* Esconde menu padrão */
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: var(--bg-dark);
        flex-direction: column;
        padding: 20px;
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }
    
    .nav-links.active {
        display: flex; /* Mostra quando ativo via JS */
    }

    .mobile-menu-btn {
        display: block; /* Mostra ícone hamburguer */
    }

    .hero-section {
        flex-direction: column;
        padding-top: 100px;
        text-align: center; /* Centraliza no mobile */
    }

    .hero-visual {
        position: relative;
        width: 100%;
        right: auto;
        margin-top: 50px;
    }

    .hero-actions {
        justify-content: center;
    }

    .about-grid {
        grid-template-columns: 1fr;
    }
    
    .section-heading::after {
        left: 50%;
        transform: translateX(-50%); /* Centraliza o sublinhado */
    }
    
    .section-heading {
        display: block;
        text-align: center;
    }
}