:root {
    --primary: #6366f1; /* Indigo */
    --dark: #0f172a;    /* Navy */
    --bg: #f8fafc;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --white: #ffffff;
    --success: #22c55e;
    --warning: #f59e0b;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background-color: var(--bg);
    color: var(--text-main);
    padding-bottom: 70px; /* Espaço para a nav mobile */
}

header {
    height: 60px;
    background-color: white;
    border-bottom: 1px solid #ddd;
    display: flex;
    justify-content: center; /* Centraliza o contêiner */
    align-items: center;
    position: relative;
    z-index: 10;
}

.header-content {
    width: 100%;
    max-width: 400px; /* AQUI: Diminua esse valor para aproximar os botões da logo */
    display: flex;
    justify-content: space-between; /* Empurra os botões para as pontas do contêiner de 400px */
    align-items: center;
    position: relative;
    padding: 0 10px;
}

.logo-container {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none; /* Garante que a logo não atrapalhe cliques nos botões */
}

.logo-img {
    height: 90px; /* Mantém sua logo grande */
    width: auto;
    filter: drop-shadow(0px 4px 4px rgba(0,0,0,0.1));
}

.nav-btn-header {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 11;
    /* Removemos o top: 50% e absolute daqui para usar o flex do header-content */

}

.side-left { left: 15px; }
.side-right { right: 15px; }

/* Modal (Janela de Ajustes) */
.modal {
    display: none; 
    position: fixed;
    z-index: 100;
    left: 0; top: 0;
    width: 100%; height: 100%;
    background-color: rgba(0,0,0,0.5);
}

.modal-content {
    background-color: white;
    margin: 20% auto;
    padding: 20px;
    border-radius: 15px;
    width: 80%;
    max-width: 400px;
    text-align: center;
}

.modal-actions {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.btn-cancel {
    background: #e2e8f0;
    border: none;
    padding: 10px;
    border-radius: 8px;
    width: 100%;
    cursor: pointer;
}

/* Feed Container */
#feed {
    max-width: 600px;
    margin: 0 auto;
    padding: 10px;
}

/* Cards de Postagem */
.post-card {
    background: var(--white);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 16px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    border: 1px solid #e2e8f0;
}

.post-header {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
}

.avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #e2e8f0;
    margin-right: 12px;
    object-fit: cover;
}

.post-info .author {
    font-weight: 700;
    font-size: 0.9rem;
    display: block;
}

.post-info .meta {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.post-content {
    font-size: 0.95rem;
    line-height: 1.5;
    margin-bottom: 12px;
}

.post-content b { color: var(--primary); }

/* Badge de Reconhecimento */
.badge-reconhecimento {
    display: inline-block;
    background: #eef2ff;
    color: var(--primary);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 10px;
}

/* Imagem do Post (Empresa) */
.post-image {
    width: 100%;
    border-radius: 8px;
    margin-top: 10px;
}

/* Ações */
.post-actions {
    border-top: 1px solid #f1f5f9;
    padding-top: 12px;
    display: flex;
    gap: 15px;
}

.action-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 5px;
    cursor: pointer;
}

/* Navegação Mobile */
.mobile-nav {
    position: fixed;
    bottom: 0;
    width: 100%;
    background: var(--white);
    display: flex;
    border-top: 1px solid #e2e8f0;
    padding: 10px 0;
    justify-content: space-around;
}

.nav-item {
    background: none;
    border: none;
    color: var(--text-muted);
    text-align: center;
    font-size: 0.7rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.nav-item.active {
    color: var(--primary);
}

.nav-item i { font-size: 1.4rem; }

/* Card de Criação no Topo */
.create-post-card {
    background: var(--white);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 20px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    border: 1px solid #e2e8f0;
}

.create-post-card h3 {
    margin: 0 0 12px 0;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.input-group {
    position: relative;
    margin-bottom: 12px;
}

.input-field {
    width: 100%;
    padding: 12px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-family: inherit;
    font-size: 0.9rem;
    outline: none;
    transition: border 0.2s;
}

.input-field:focus {
    border-color: var(--primary);
}

/* Lista de Sugestões (Autocomplete) */
.suggestions-list {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 0 0 8px 8px;
    z-index: 10;
    max-height: 150px;
    overflow-y: auto;
    display: none; /* Escondido por padrão */
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.suggestion-item {
    padding: 10px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
}

.suggestion-item:hover {
    background: #f1f5f9;
}

.btn-publish {
    width: 100%;
    background: var(--primary);
    color: white;
    border: none;
    padding: 10px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.2s;
}

.btn-publish:disabled {
    background: #cbd5e1;
    cursor: not-allowed;
}

/* Estilos para a Tela de Feedbacks */
.feedback-card {
    background: var(--white);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 15px;
    border-left: 6px solid #cbd5e1; /* Cor padrão */
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

/* Cores por tipo de Feedback */
.feedback-card.positivo { border-left-color: #22c55e; }
.feedback-card.melhoria { border-left-color: #f59e0b; }
.feedback-card.alerta { border-left-color: #ef4444; }

.feedback-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.feedback-author {
    font-weight: bold;
    font-size: 0.9rem;
    color: var(--text-main);
}

.feedback-type {
    font-size: 0.7rem;
    text-transform: uppercase;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: 4px;
    background: #f1f5f9;
}

.feedback-body {
    display: flex;
    gap: 15px;
    align-items: flex-start;
}

.feedback-emoji {
    font-size: 2rem;
}

.feedback-text {
    font-size: 0.95rem;
    line-height: 1.4;
    color: #334155;
}

.feedback-date {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 10px;
    display: block;
}

/* Tela de Perfil */
.profile-header {
    background: var(--white);
    border-radius: 15px;
    padding: 25px;
    text-align: center;
    margin-bottom: 20px;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05);
}

.profile-avatar-large {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border: 4px solid var(--primary);
    margin-bottom: 15px;
}

.profile-name {
    font-size: 1.4rem;
    font-weight: 800;
    margin: 0;
    color: var(--dark);
}

.profile-role {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 15px;
    display: block;
}

.profile-bio {
    font-style: italic;
    font-size: 0.9rem;
    color: var(--text-main);
    background: #f8fafc;
    padding: 10px;
    border-radius: 8px;
    margin-bottom: 15px;
}

.profile-stats {
    display: flex;
    justify-content: center;
    gap: 30px;
    border-top: 1px solid #f1f5f9;
    padding-top: 15px;
}

.stat-item {
    display: flex;
    flex-direction: column;
}

.stat-value {
    font-weight: 800;
    font-size: 1.2rem;
    color: var(--primary);
}

.stat-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    color: var(--text-muted);
}

.section-title {
    font-size: 1rem;
    font-weight: 700;
    margin: 20px 0 10px 5px;
    color: var(--dark);
}

.recon-history-item {
    background: var(--white);
    padding: 12px;
    border-radius: 10px;
    margin-bottom: 8px;
    font-size: 0.85rem;
    border-left: 4px solid #e2e8f0;
}

/* Botão Flutuante (FAB) */
.fab-button {
    position: fixed;
    bottom: 90px; /* Aumentado de 20px para 90px */
    right: 20px;
    width: 55px;  /* Leve aumento para melhor toque */
    height: 50px;
    background-color: #007bff;
    color: white;
    border-radius: 50%;
    border: none;
    font-size: 24px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3); /* Sombra um pouco mais profunda */
    z-index: 1000;
    transition: transform 0.2s, background-color 0.2s;
    display: flex; /* Garante centralização do ícone */
    align-items: center;
    justify-content: center;
}

.fab-button:hover {
    transform: scale(1.1);
}

/* Modal */
.custom-modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
}

.modal-content {
    background-color: white;
    margin: 15% auto;
    padding: 25px;
    border-radius: 12px;
    width: 90%;
    max-width: 400px;
    position: relative;
    text-align: center;
}

.close-modal {
    position: absolute;
    right: 15px;
    top: 10px;
    font-size: 24px;
    cursor: pointer;
    color: #999;
}

/* Ajustes no corpo do modal para alinhar o texto à esquerda */
.modal-body {
    text-align: left;
    margin-top: 20px;
}

/* Espaçamento entre os blocos de pergunta */
.form-group {
    margin-bottom: 16px;
}

/* Estilização dos títulos (Labels) */
.form-group label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 6px;
    margin-left: 2px;
}

/* Melhoria no Modal Content para não centralizar tudo */
.modal-content {
    background-color: white;
    margin: 15% auto; /* Diminuí a margem superior */
    padding: 24px;
    border-radius: 16px;
    width: 90%;
    max-width: 400px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

.modal-content h3 {
    margin-top: 0;
    color: var(--dark);
    font-size: 1.2rem;
}

/* Ajuste nos botões para ficarem um ao lado do outro ou empilhados */
.modal-actions {
    display: flex;
    flex-direction: column; /* No mobile, botões empilhados são melhores */
    gap: 10px;
    margin-top: 24px;
}

/* Se quiser botões lado a lado em telas maiores */
@media (min-width: 400px) {
    .modal-actions {
        flex-direction: row-reverse;
    }
}

/* Container de ações */
.post-actions {
    display: flex;
    gap: 16px;
    padding: 12px 0;
    border-top: 1px solid #efefef;
}

.action-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    font-weight: 600;
    color: #262626;
    transition: transform 0.1s ease;
}

.action-btn:active {
    transform: scale(0.9);
}

.action-btn.liked {
    color: #ed4956; /* Vermelho do Instagram */
}

/* Seção de comentários escondida por padrão */
.comentarios-section {
    display: none;
    padding-bottom: 12px;
}

.comentarios-section.show {
    display: block;
}

.comentario-item {
    font-size: 14px;
    margin: 4px 0;
    line-height: 1.4;
}

/* Input de comentário estilo clean */
.input-comentario {
    width: 100%;
    border: none;
    border-top: 1px solid #efefef;
    padding: 12px 0;
    outline: none;
    font-size: 14px;
}

.input-comentario::placeholder {
    color: #8e8e8e;
}

/* Estilo para as respostas */
.comentario-resposta {
    margin-left: 45px; /* Recuo para parecer resposta */
    margin-top: 5px;
    border-left: 2px solid #e2e8f0; /* Linha sutil conectando à resposta */
    padding-left: 10px;
}

/* Deixar o @nome em azul/negrito igual Instagram */
.mencao-usuario {
    color: #00376b;
    font-weight: 600;
    text-decoration: none;
}

.author:hover,
.comentario-item b:hover {
    text-decoration: underline;
}

.mencao-usuario {
    color: #3b82f6;
    font-weight: bold;
    cursor: pointer;
}

.carousel {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
}

.carousel-img {
    width: 100%;
    max-width: 300px;
    margin-right: 10px;
    border-radius: 10px;
    scroll-snap-align: center;
}

.dots {
    display: flex;
    justify-content: center;
    margin-top: 8px;
}

.dot {
    width: 6px;
    height: 6px;
    background: #ccc;
    border-radius: 50%;
    margin: 0 3px;
}

.dot.active {
    background: #000000;
}

.post-content b {
    font-size: 16px;
    display: block;
}

.carousel {
    display: flex;
    overflow-x: auto;
    gap: 10px;
}

.carousel-img {
    width: 250px;
    border-radius: 10px;
}

.post-titulo {
    color: #111 !important;
    font-size: 16px;
    font-weight: bold;
}

/* Espaçamento entre os campos do card de postagem */
.create-post-card .input-field {
    margin-bottom: 12px;
}

/* Container do seletor de arquivos */
.file-input-wrapper {
    margin-bottom: 15px;
}

/* Esconde o input original */
.file-input-wrapper input[type="file"] {
    display: none;
}

/* Estilização do botão "Adicionar Fotos" */
.btn-add-photo {
    display: inline-block;
    padding: 8px 16px;
    background-color: #f1f5f9;
    color: var(--text-main);
    border: 2px dashed #cbd5e1;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 600;
    transition: all 0.2s ease;
    text-align: center;
    width: 100%; /* Ocupa a largura total, ou remova para ficar compacto */
}

.btn-add-photo:hover {
    background-color: #e2e8f0;
    border-color: var(--primary);
    color: var(--primary);
}

/* Ajuste no Preview para não colar nos botões */
.preview-container {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

/* Container das ações dentro do modal */
.modal-photo-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 15px;
}

/* Botões de Opção (Ver e Alterar) */
.btn-modal-option {
    width: 100%;
    padding: 14px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    background-color: var(--white);
    color: var(--text-main);
    font-size: 0.95rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-modal-option span {
    font-size: 1.1rem;
}

.btn-modal-option:hover {
    background-color: #f8fafc;
    border-color: #cbd5e1;
}

/* Destaque para o botão de alterar (opcional) */
.btn-modal-option.primary {
    color: var(--primary);
    background-color: #eef2ff;
    border-color: #c7d2fe;
}

.btn-modal-option.primary:hover {
    background-color: #e0e7ff;
}

/* Linha divisória sutil */
.modal-divider {
    border: 0;
    border-top: 1px solid #f1f5f9;
    margin: 8px 0;
}

/* Botão Cancelar */
.btn-modal-cancel {
    width: 100%;
    padding: 12px;
    border: none;
    background: none;
    color: #ef4444; /* Vermelho para indicar cancelamento/fechar */
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: opacity 0.2s;
}

.btn-modal-cancel:hover {
    opacity: 0.7;
    text-decoration: underline;
}


/* ===== BUSCA DE PERFIL PROFISSIONAL ===== */

.search-profile-container {
    width: 100%;
    margin-bottom: 24px;
    position: relative;
    z-index: 20;
    font-family: 'Inter', sans-serif; /* Recomendado para SaaS */
}

.search-toggle-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    height: 48px;
    background: #ffffff;
    /* Borda sutil em vez de sólida colorida */
    border: 1px solid #e2e8f0; 
    border-radius: 10px;
    color: #475569;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.search-toggle-btn:hover {
    background: #f8fafc;
    border-color: #6366f1;
    color: #6366f1;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.1);
}

.search-toggle-btn span:first-child {
    font-size: 1.1rem;
    transition: transform 0.3s ease;
}

.search-toggle-btn:active {
    transform: scale(0.98);
}

/* Box de Pesquisa (Efeito Card Elevado) */
.search-profile-box {
    display: none;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(8px); /* Efeito Glassmorphism leve */
    border-radius: 12px;
    border: 1px solid rgba(226, 232, 240, 0.8);
    padding: 12px;
    margin-top: 8px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
    animation: slideDown 0.3s ease-out;
}

.search-profile-box.active {
    display: block;
}

/* Input de Pesquisa */
#searchPerfilInput {
    width: 100%;
    height: 42px;
    padding: 0 16px;
    background: #f1f5f9;
    border: 1px solid transparent;
    border-radius: 8px;
    outline: none;
    font-size: 14px;
    color: #1e293b;
    transition: all 0.2s ease;
}

#searchPerfilInput:focus {
    background: #ffffff;
    border-color: #6366f1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
}

/* Container de Resultados */
.resultado-busca {
    max-height: 250px;
    overflow-y: auto;
    margin-top: 8px;
}

/* Scrollbar Customizada */
.resultado-busca::-webkit-scrollbar {
    width: 6px;
}
.resultado-busca::-webkit-scrollbar-thumb {
    background: #e2e8f0;
    border-radius: 10px;
}

/* Animação de Entrada */
@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ===== ITENS DO RESULTADO DA BUSCA ===== */

.item-usuario-busca {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.item-usuario-busca:hover {
    background: #f8fafc;
    border-color: #e2e8f0;
    transform: translateX(4px); /* Feedback visual de movimento */
}

/* Estilização da Foto */
.item-usuario-busca img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

/* Textos (Nome e Cargo) */
.item-usuario-busca .nome {
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 2px;
}

.item-usuario-busca .cargo {
    font-size: 12px;
    color: #64748b;
    text-transform: capitalize;
}

/* Estado: Nenhum resultado encontrado */
.no-results {
    padding: 20px;
    text-align: center;
    color: #94a3b8;
    font-size: 13px;
}