/* ======================================================
   STYLE.CSS - HUB LUMIÔ (V 4.0 - FINAL E CORRIGIDO)
   ====================================================== */

/* 1. CONFIGURAÇÕES GERAIS */
html { scroll-behavior: smooth; }
body { 
    background-color: #0f172a; /* Slate 900 */ 
    color: #e2e8f0;
    font-family: 'Inter', sans-serif;
    overflow-x: hidden; 
    margin: 0; padding: 0;
}

/* Fontes Especiais */
.code-font { font-family: 'JetBrains Mono', monospace; }

/* Scrollbar Personalizada */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #0f172a; }
::-webkit-scrollbar-thumb { background: #334155; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #4ade80; }

/* ======================================================
   2. EFEITOS VISUAIS (NEON & GLOW)
   ====================================================== */
.neon-text {
    color: #4ade80;
    text-shadow: 0 0 10px rgba(74, 222, 128, 0.5), 0 0 20px rgba(74, 222, 128, 0.3);
}

/* Botão Neon Principal */
.btn-neon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    background-color: transparent;
    border: 1px solid #4ade80;
    color: #4ade80;
    text-transform: uppercase;
    font-weight: bold;
    border-radius: 8px;
    letter-spacing: 1px;
    box-shadow: 0 0 10px rgba(74, 222, 128, 0.1);
    transition: all 0.3s ease;
    cursor: pointer;
    text-decoration: none;
}

.btn-neon:hover {
    background-color: #4ade80;
    color: #0f172a;
    box-shadow: 0 0 20px rgba(74, 222, 128, 0.6);
    transform: translateY(-2px);
}

/* Botão de Envio Padrão */
.btn-submit {
    width: 100%;
    background-color: #22c55e;
    color: #0f172a;
    font-weight: bold;
    padding: 12px;
    border: none;
    border-radius: 8px;
    transition: all 0.3s;
    margin-top: 15px;
    cursor: pointer;
    font-size: 1rem;
}
.btn-submit:hover { background-color: #4ade80; transform: scale(1.02); }

/* ======================================================
   3. CARDS E ELEMENTOS
   ====================================================== */
/* Card de Tecnologia (Vitrine) */
.tech-card {
    background: rgba(30, 41, 59, 0.7);
    border: 1px solid #334155;
    border-radius: 12px;
    padding: 1.5rem;
    backdrop-filter: blur(10px);
    transition: all 0.4s ease;
    display: flex; flex-direction: column;
    height: 100%; /* Garante altura igual */
}

.tech-card:hover {
    border-color: #4ade80;
    transform: translateY(-5px);
    box-shadow: 0 10px 30px -10px rgba(74, 222, 128, 0.2);
}

/* Imagens dentro dos cards */
.tech-card img {
    width: 64px; height: 64px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #22c55e;
}

/* Card de Sistema (Arquitetura) */
.system-card {
    background: #1e293b;
    padding: 24px;
    border-radius: 16px;
    border-top: 4px solid transparent;
    transition: all 0.3s;
    height: 100%;
}

.system-card:hover { transform: translateY(-5px); background: #334155; }
/* Cores das Bordas dos Sistemas */
.system-card:nth-child(1) { border-color: #3b82f6; } /* Core - Azul */
.system-card:nth-child(2) { border-color: #22c55e; } /* Digital - Verde */
.system-card:nth-child(3) { border-color: #eab308; } /* Rede - Amarelo */
.system-card:nth-child(4) { border-color: #a855f7; } /* IA - Roxo */

.system-icon-box {
    width: 48px; height: 48px;
    background: rgba(255,255,255,0.05);
    border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    margin-bottom: 16px;
}

.system-card ul { list-style: none; padding: 0; margin: 0; color: #94a3b8; font-size: 0.9rem; font-family: 'JetBrains Mono', monospace; }
.system-card li { margin-bottom: 0.5rem; display: flex; align-items: center; }

/* ======================================================
   4. MODAIS E INPUTS (FIXED)
   ====================================================== */
.modal-overlay {
    display: none; /* Controlado via JS (flex) */
    position: fixed;
    inset: 0; /* Top/Left/Right/Bottom 0 */
    width: 100%; height: 100%;
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(8px); /* Efeito Vidro */
    z-index: 10000; /* Acima do chat */
    justify-content: center;
    align-items: center;
    padding: 20px;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* Inputs Globais */
input, select, textarea {
    width: 100%;
    background: #0f172a;
    border: 1px solid #334155;
    color: white;
    padding: 12px;
    border-radius: 8px;
    outline: none;
    transition: border 0.3s;
    font-family: inherit;
    box-sizing: border-box;
}

input:focus, select:focus, textarea:focus { border-color: #4ade80; }

/* Barra de Busca Redonda */
.search-wrapper { position: relative; max-width: 600px; margin: 0 auto 2rem; }
.search-icon-position { position: absolute; left: 1rem; top: 50%; transform: translateY(-50%); color: #64748b; }
#tech-search {
    border-radius: 9999px;
    padding-left: 3rem;
    background-color: #1e293b;
    border-color: #334155;
}

#search-counter { text-align: center; color: #64748b; font-size: 0.85rem; margin-top: 0.5rem; font-family: 'JetBrains Mono', monospace; }

/* ======================================================
   5. DASHBOARD & ANIMAÇÕES
   ====================================================== */
.bar-container {
    width: 100%;
    background-color: #334155;
    border-radius: 9999px;
    height: 8px;
    overflow: hidden;
}

.bar-fill {
    width: 0%; /* JS preenche */
    height: 100%;
    background-color: #4ade80;
    border-radius: 9999px;
    transition: width 1.5s ease-out; /* Animação suave */
}

/* ======================================================
   6. COMUNIDADE DE VALIDAÇÃO (Form)
   ====================================================== */
.section-validation { padding: 80px 20px; background-color: #0f172a; }
.form-container { 
    max-width: 600px; margin: 0 auto; 
    background: #1e293b; padding: 30px; 
    border-radius: 16px; border: 1px solid #334155; 
}
.form-container h3 { color: white; margin-bottom: 20px; font-weight: bold; font-size: 1.5rem; text-align: center; }

.form-row { display: flex; gap: 15px; margin-bottom: 15px; }
@media (max-width: 600px) { .form-row { flex-direction: column; } }

/* Estrelas */
.star-rating-container {
    display: flex; align-items: center; justify-content: space-between;
    background: #0f172a; padding: 10px; border: 1px solid #334155; border-radius: 8px;
}
.interactive-stars { display: flex; gap: 5px; cursor: pointer; }
.star-icon { width: 24px; height: 24px; color: #475569; transition: color 0.2s; }
.star-icon.filled { color: #fbbf24; fill: #fbbf24; }

/* Testemunhos */
.testimonials-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; margin-bottom: 40px; }
.testimony-card { background: #1e293b; padding: 20px; border-radius: 12px; border: 1px solid #334155; animation: fadeIn 0.5s; }
.card-header { display: flex; justify-content: space-between; margin-bottom: 10px; }
.author-info h3 { margin: 0; font-size: 1rem; color: white; }
.author-info .location { color: #94a3b8; font-size: 0.8rem; }
.stars { color: #fbbf24; letter-spacing: 2px; }

/* ======================================================
   7. CHAT GÊNIO LUMIÔ (CORRIGIDO)
   ====================================================== */
#genio-chat-window {
    position: fixed; bottom: 90px; right: 20px;
    width: 350px; height: 450px;
    background: #1e293b;
    border: 1px solid #4ade80; /* Borda Verde Neon */
    border-radius: 16px;
    z-index: 9990;
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
    display: flex; flex-direction: column;
    overflow: hidden;
    
    /* ESTADO INICIAL: FECHADO/INVISÍVEL */
    opacity: 0;
    pointer-events: none;
    transform: translateY(20px);
    
    /* Transição suave */
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ESTADO ABERTO (Adicionado via JS) */
#genio-chat-window.open {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

/* Botão Flutuante */
#genio-btn {
    position: fixed; bottom: 20px; right: 20px;
    width: 60px; height: 60px;
    background: #22c55e;
    border-radius: 50%;
    color: #0f172a;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 0 20px rgba(34, 197, 94, 0.4);
    transition: transform 0.2s;
    z-index: 9991; cursor: pointer; border: none;
}
#genio-btn:hover { transform: scale(1.1); }

#chat-messages { flex: 1; padding: 15px; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; }

/* Animações Chat */
@keyframes slideUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
.animate-slideUp { animation: slideUp 0.3s ease; }

/* Balões de Mensagem */
.msg {
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    font-size: 0.9rem;
    max-width: 85%;
    line-height: 1.4;
}
.msg.user {
    background-color: #4ade80; color: #0f172a; align-self: flex-end; border-top-right-radius: 0; font-weight: bold;
}
.msg.bot {
    background-color: #334155; color: white; align-self: flex-start; border-top-left-radius: 0; border: 1px solid #475569;
}

/* ======================================================
   8. TELA DE CARREGAMENTO (LOADING)
   ====================================================== */
#welcome-screen-slate {
    position: fixed; top: 0; left: 0;
    width: 100%; height: 100%;
    background: #0f172a;
    z-index: 10000;
    display: flex; /* Começa visível */
    align-items: center; justify-content: center;
    transition: opacity 0.5s;
    opacity: 1;
}

/* Classe utilitária para esconder */
.hidden { display: none !important; }

.welcome-content-slate { text-align: center; }
.slate-title { font-size: 3rem; font-weight: 800; color: white; letter-spacing: -2px; margin-bottom: 10px; }
.slate-subtitle { color: #94a3b8; font-family: 'JetBrains Mono', monospace; margin-bottom: 30px; }

.slate-loader {
    width: 40px; height: 40px;
    border: 3px solid #334155;
    border-top-color: #4ade80;
    border-radius: 50%;
    margin: 0 auto;
    animation: spin 1s linear infinite;
}
@keyframes spin { 100% { transform: rotate(360deg); } }

/* ======================================================
   9. BADGES & GAMIFICAÇÃO (PARA NÃO FICAR BAGUNÇADO)
   ====================================================== */
.badge-nivel {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 4px;
}

.badge-ouro { 
    background: rgba(234, 179, 8, 0.1); 
    border: 1px solid rgba(234, 179, 8, 0.3); 
    color: #facc15; 
}

.badge-prata { 
    background: rgba(59, 130, 246, 0.1); 
    border: 1px solid rgba(59, 130, 246, 0.3); 
    color: #60a5fa; 
}

/* Responsividade Mobile */
@media (max-width: 640px) {
    .slate-title { font-size: 2rem; }
    #genio-chat-window { width: 90%; right: 5%; bottom: 85px; }
}

/* ======================================================
   10. NOTIFICAÇÕES PREMIUM (TOASTS)
   ====================================================== */
#toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 11000; /* Acima de tudo */
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toast {
    background: rgba(15, 23, 42, 0.95);
    border-left: 4px solid;
    padding: 16px 24px;
    border-radius: 8px;
    color: white;
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 300px;
    
    /* Animação de Entrada */
    transform: translateX(100%);
    opacity: 0;
    animation: slideIn 0.3s forwards;
}

.toast.success { border-color: #22c55e; }
.toast.success i { color: #22c55e; }

.toast.error { border-color: #ef4444; }
.toast.error i { color: #ef4444; }

@keyframes slideIn {
    to { transform: translateX(0); opacity: 1; }
}

@keyframes slideOut {
    to { transform: translateX(100%); opacity: 0; }
}