/* ========================================================= */
/* DESIGN TOKENS - BIOTECH / IoT (Silicon Valley Standard)   */
/* ========================================================= */
:root {
    /* Cores de Fundo (Zinc Scale) */
    --bg-base: #09090b;       
    --bg-surface: #18181b;    
    --bg-surface-hover: #27272a; 
    
    /* Bordas */
    --border-subtle: rgba(255, 255, 255, 0.08);
    --border-strong: rgba(255, 255, 255, 0.15);
    
    /* Tipografia */
    --text-primary: #fafafa;   
    --text-secondary: #a1a1aa; 
    --text-muted: #71717a;     
    
    /* Acentos IoT */
    --accent-iot: #10b981; /* Verde Esmeralda (Saúde/Sensores) */
    --accent-iot-glow: rgba(16, 185, 129, 0.15);
    --accent-blue: #3b82f6; /* Azul (Refrigeração/Wi-Fi) */
    
    /* Variáveis Estruturais */
    --font-code: 'JetBrains Mono', ui-monospace, monospace;
    --ease-smooth: cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --transition: all 0.3s var(--ease-smooth);
    
    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 24px;
}

/* ========================================================= */
/* BASE & RESET                                              */
/* ========================================================= */
* { 
    margin: 0; 
    padding: 0; 
    box-sizing: border-box; 
}

html { 
    scroll-behavior: smooth; 
    scroll-padding-top: 100px; 
}

body {
    background-color: var(--bg-base);
    color: var(--text-primary);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.7;
    
    /* Padrão Blueprint (Grade de Engenharia Sutil) no Fundo */
    background-image: 
        linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
    background-size: 40px 40px;
    background-attachment: fixed;

    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* Seleção de Texto Customizada */
::selection {
    background-color: rgba(16, 185, 129, 0.3);
    color: #ffffff;
}

/* Custom Scrollbar Global */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: var(--bg-base); }
::-webkit-scrollbar-thumb { background: #3f3f46; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #52525b; }

/* Acessibilidade de Foco (A11y) */
a:focus-visible, button:focus-visible { 
    outline: 2px solid var(--accent-iot); 
    outline-offset: 4px; 
    border-radius: 2px;
}
*:focus:not(:focus-visible) { outline: none; }

/* ========================================================= */
/* UTILITÁRIOS E LAYOUT                                      */
/* ========================================================= */
.container { width: 100%; max-width: 1100px; margin: 0 auto; padding: 0 1.5rem; }
.section-padding { padding: 7rem 0; }
.pt-0 { padding-top: 0 !important; }
.mt-4 { margin-top: 1.5rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-4 { margin-bottom: 1.5rem; }

h1, h2, h3, h4 { letter-spacing: -0.03em; line-height: 1.2; }
.category-title { font-size: 0.9rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--accent-iot); font-weight: 600; margin-bottom: 1rem; }

/* ========================================================= */
/* NAVBAR BIOTECH                                            */
/* ========================================================= */
.navbar {
    position: fixed; top: 0; left: 0; width: 100%;
    background: transparent;
    padding: 1.2rem 0;
    z-index: 1000;
    transition: var(--transition);
    border-bottom: 1px solid transparent;
}

.nav-container { display: flex; justify-content: space-between; align-items: center; }

.logo { 
    font-size: 1.3rem; font-weight: 700; color: var(--text-primary); 
    text-decoration: none; display: flex; align-items: center; gap: 0.5rem; 
}
.logo i { color: var(--accent-iot); }

.nav-back-btn { 
    display: inline-flex; align-items: center; gap: 0.5rem; 
    color: var(--text-secondary); text-decoration: none; 
    font-weight: 500; font-size: 0.9rem; transition: var(--transition); 
}
.nav-back-btn:hover { color: var(--text-primary); transform: translateX(-4px); }

.nav-links { display: flex; gap: 2rem; list-style: none; }
.nav-links a { 
    color: var(--text-secondary); text-decoration: none; 
    font-size: 0.9rem; font-weight: 500; transition: var(--transition); 
}
.nav-links a:hover, .nav-links a.active { color: var(--text-primary); }

.hamburger { display: none; flex-direction: column; gap: 5px; cursor: pointer; }
.hamburger span { width: 25px; height: 2px; background: var(--text-primary); transition: var(--transition); }

@media (max-width: 900px) {
    .nav-links { 
        display: none; position: absolute; top: 65px; right: 1.5rem; 
        background: rgba(24, 24, 27, 0.95); backdrop-filter: blur(12px);
        padding: 1.5rem; border: 1px solid var(--border-subtle); 
        border-radius: var(--radius-sm); flex-direction: column; gap: 1.2rem; 
        box-shadow: 0 15px 30px rgba(0,0,0,0.5); 
    }
    .nav-links.active { display: flex; }
    .hamburger { display: flex; }
}

/* ========================================================= */
/* HERO SECTION (VÍDEO BRUTALISTA)                           */
/* ========================================================= */
.hero {
    position: relative;
    min-height: 85vh;
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--border-subtle);
    overflow: hidden;
}

.hero-video {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    object-fit: cover; z-index: -2;
}

.hero-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(to right, rgba(9,9,11,1) 10%, rgba(9,9,11,0.85) 60%, rgba(9,9,11,0.5) 100%);
    z-index: -1;
}

.hero-content { position: relative; z-index: 1; max-width: 750px; padding-top: 4rem; }

.status-badge {
    display: inline-flex; align-items: center; gap: 0.5rem;
    padding: 0.4rem 1rem; border-radius: 50px;
    background-color: var(--accent-iot-glow); 
    border: 1px solid rgba(16, 185, 129, 0.3);
    font-size: 0.85rem; color: var(--accent-iot); margin-bottom: 1.5rem;
    font-weight: 500;
}
.pulse-dot { 
    width: 8px; height: 8px; background-color: var(--accent-iot); 
    border-radius: 50%; box-shadow: 0 0 10px var(--accent-iot); 
    animation: pulse 2s infinite; 
}
@keyframes pulse { 0% { opacity: 1; } 50% { opacity: 0.4; } 100% { opacity: 1; } }

.hero-title { font-size: clamp(2.5rem, 5vw, 4rem); font-weight: 700; margin-bottom: 1.5rem; }
.hero-title span { color: var(--accent-iot); }
.hero-subtitle { font-size: 1.15rem; color: var(--text-secondary); margin-bottom: 2.5rem; max-width: 650px; }

.tech-pills { display: flex; flex-wrap: wrap; gap: 0.8rem; }
.pill { 
    font-size: 0.85rem; padding: 0.4rem 1rem; border-radius: 50px; 
    background: rgba(255,255,255,0.05); border: 1px solid var(--border-subtle); 
    font-family: var(--font-code); color: var(--text-primary);
    display: inline-flex; align-items: center; gap: 0.4rem;
}

/* ========================================================= */
/* BENTO BOX (FUNCIONALIDADES CORE)                          */
/* ========================================================= */
.section-header { margin-bottom: 3rem; max-width: 650px; }
.section-header h2 { font-size: 2.2rem; margin-bottom: 0.5rem; color: var(--text-primary); }
.section-header p { color: var(--text-secondary); font-size: 1.1rem; }

.bento-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.5rem; }

.bento-card { 
    background: var(--bg-surface); padding: 2.5rem 2rem; 
    border-radius: var(--radius-md); border: 1px solid var(--border-subtle); 
    /* A transição do tilt é controlada no JS, aqui focamos nas cores */
    transition: background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease; 
}

.bento-card:hover { 
    border-color: rgba(16, 185, 129, 0.4); 
    background: var(--bg-surface-hover);
    box-shadow: 0 15px 35px rgba(0,0,0,0.4); 
}

.bento-icon { font-size: 2.5rem; color: var(--accent-iot); margin-bottom: 1.5rem; display: block; }
.bento-title { font-size: 1.25rem; margin-bottom: 1rem; color: var(--text-primary); }
.bento-text { color: var(--text-secondary); font-size: 0.95rem; }

/* ========================================================= */
/* GRADE DE TECNOLOGIAS (IMAGENS)                            */
/* ========================================================= */
.tech-grid-visual { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 1rem; }

.tech-item { 
    background: var(--bg-surface); border: 1px solid var(--border-subtle); 
    padding: 1.5rem; border-radius: var(--radius-sm); 
    display: flex; flex-direction: column; align-items: center; text-align: center; gap: 1rem; 
    transition: background-color 0.3s ease, border-color 0.3s ease; 
}
.tech-item img { width: 60px; height: 60px; object-fit: contain; filter: grayscale(100%); transition: var(--transition); }
.tech-item span { font-size: 0.85rem; font-weight: 500; color: var(--text-secondary); transition: var(--transition); }

.tech-item:hover { border-color: var(--border-strong); background: var(--bg-surface-hover); }
.tech-item:hover img { filter: grayscale(0%); }
.tech-item:hover span { color: var(--text-primary); }

/* ========================================================= */
/* DETALHES PROFUNDOS (LAYOUT MISTO)                         */
/* ========================================================= */
.details-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: start; }

@media (max-width: 900px) { .details-layout { grid-template-columns: 1fr; gap: 3rem; } }

.tech-list { list-style: none; }
.tech-list li { display: flex; align-items: flex-start; gap: 1rem; margin-bottom: 1.2rem; color: var(--text-secondary); font-size: 1rem; }
.tech-list i { color: var(--accent-iot); margin-top: 0.3rem; font-size: 0.85rem; }

/* ========================================================= */
/* IDE WINDOW (CÓDIGO FONTE - ESTILO VS CODE)                */
/* ========================================================= */
.ide-window { 
    background: #1e1e1e; /* Cor oficial fundo VS Code Dark+ */
    border-radius: var(--radius-md); 
    border: 1px solid #333333; 
    overflow: hidden; 
    box-shadow: 0 25px 50px rgba(0,0,0,0.5); 
}

.ide-header { 
    background: #252526; /* Cor aba superior VS Code */
    padding: 0.8rem 1rem; display: flex; align-items: center; 
    border-bottom: 1px solid #111111; 
}

.ide-dots { display: flex; gap: 6px; margin-right: 1.5rem; }
.ide-dots span { width: 12px; height: 12px; border-radius: 50%; background: #444; }
.ide-dots span:nth-child(1) { background: #ff5f56; } /* Close */
.ide-dots span:nth-child(2) { background: #ffbd2e; } /* Minimize */
.ide-dots span:nth-child(3) { background: #27c93f; } /* Maximize */

.ide-tabs { display: flex; gap: 1rem; }
.tab-btn { 
    background: transparent; border: none; color: #858585; 
    font-family: var(--font-code); font-size: 0.85rem; 
    cursor: pointer; transition: var(--transition); 
}
.tab-btn.active { color: #ffffff; }
.tab-btn:hover:not(.active) { color: #cccccc; }

.ide-body { padding: 1.5rem; font-family: var(--font-code); font-size: 0.85rem; line-height: 1.6; }
.code-tab { display: none; }
.code-tab.active { display: block; animation: fadeIn 0.4s ease; }

.code-wrapper { 
    max-height: 250px; overflow: hidden; position: relative; 
    transition: max-height 0.6s cubic-bezier(0.25, 1, 0.5, 1); 
}
.code-wrapper.expanded { max-height: 2500px; }

/* Gradiente de fade-out combinando exatamente com o fundo #1e1e1e */
.code-wrapper::after { 
    content: ''; position: absolute; bottom: 0; left: 0; width: 100%; height: 80px; 
    background: linear-gradient(transparent, #1e1e1e); 
    pointer-events: none; transition: opacity 0.3s ease; 
}
.code-wrapper.expanded::after { opacity: 0; }

.expand-code-btn { 
    background: #2d2d30; border: 1px solid #3e3e42; color: #cccccc; 
    padding: 0.6rem 1rem; border-radius: var(--radius-sm); font-size: 0.85rem; 
    cursor: pointer; display: flex; align-items: center; gap: 0.5rem; margin-top: 1.5rem; 
    transition: var(--transition); width: 100%; justify-content: center;
}
.expand-code-btn:hover { background: #3e3e42; color: #ffffff; }

/* Custom Scrollbar da IDE */
.ide-body pre { color: #d4d4d4; overflow-x: auto; padding-bottom: 0.5rem;}
.ide-body pre::-webkit-scrollbar { height: 6px; }
.ide-body pre::-webkit-scrollbar-thumb { background: #4a4a4a; border-radius: 3px; }

/* Syntax Highlighting (C++ / Arduino) */
.keyword { color: #c586c0; } /* Roxo (Control) */
.string { color: #ce9178; }  /* Laranja (String) */
.comment { color: #6a9955; font-style: italic; } /* Verde (Comment) */
.function { color: #dcdcaa; } /* Amarelo (Function/Method) */
.number { color: #b5cea8; }  /* Verde Claro (Number) */

/* ========================================================= */
/* CHART & GALERIA                                           */
/* ========================================================= */
.chart-container { 
    background: var(--bg-surface); padding: 2rem; border-radius: var(--radius-md); 
    border: 1px solid var(--border-subtle); height: 400px; position: relative;
}

.photos-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.5rem; }
.photos-grid img { 
    width: 100%; aspect-ratio: 4/3; object-fit: cover; border-radius: var(--radius-sm); 
    border: 1px solid var(--border-subtle); filter: grayscale(50%); transition: var(--transition); 
}
.photos-grid img:hover { filter: grayscale(0%); transform: scale(1.03); box-shadow: 0 10px 20px rgba(0,0,0,0.5); }

/* ========================================================= */
/* SEÇÃO DE EQUIPE (JUSTA E ELEGANTE)                        */
/* ========================================================= */
.border-top { border-top: 1px solid var(--border-subtle); padding-top: 5rem; }

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1.5rem;
}

.team-member {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none; 
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.team-member:not(.interactive-member) {
    /* Impede o hover 3d nos membros normais via css (js gerencia o tilt se a classe existir) */
}

.member-avatar {
    width: 80px; height: 80px;
    border-radius: 50%;
    margin-bottom: 1.2rem;
}

.member-avatar img {
    width: 100%; height: 100%;
    object-fit: cover;
    border-radius: 50%;
    border: 2px solid var(--border-strong);
    background-color: var(--bg-base);
}

.member-info h4 { font-size: 1rem; color: var(--text-primary); margin-bottom: 0.3rem; }
.member-info span { font-size: 0.85rem; color: var(--text-secondary); }

/* SEU CARD (O Destaque Discreto e Interativo) */
.interactive-member {
    background: linear-gradient(145deg, var(--bg-surface), rgba(16, 185, 129, 0.05));
    border-color: rgba(16, 185, 129, 0.3);
    cursor: pointer;
}

.interactive-member:hover {
    border-color: var(--accent-iot);
    box-shadow: 0 15px 35px rgba(16, 185, 129, 0.15);
}

.member-link-text {
    color: var(--accent-iot) !important;
    font-weight: 500;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}
.interactive-member:hover .member-link-text { color: var(--text-primary) !important; }

/* ========================================================= */
/* ANIMAÇÕES GLOBAIS E FOOTER                                */
/* ========================================================= */
.reveal { opacity: 0; transform: translateY(30px); transition: all 0.8s var(--ease-smooth); }
.reveal.active { opacity: 1; transform: translateY(0); }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

.footer { padding: 3rem 0; border-top: 1px solid var(--border-subtle); text-align: center; color: var(--text-secondary); font-size: 0.9rem; }

/* Acessibilidade para Movimento Reduzido */
@media (prefers-reduced-motion: reduce) {
    * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
    .reveal { opacity: 1 !important; transform: none !important; }
}