/* ===========================
   Globais
=========================== */
html, body {
  height: 100%;
  margin: 0;
  padding: 0;
}
body {
  font-family: "Poppins", "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  background-color: #f8f9fa;
  color: #212529;
  line-height: 1.6;
}

/* Links */
a { text-decoration: none; }
a:hover { opacity: 0.8; }

/* ===========================
   Variáveis
=========================== */
:root {
  --gradient: linear-gradient(90deg, #3cd070, #3ca9f0, #9d6df0);
}

/* ===========================
   Navbar
=========================== */
.navbar { background: var(--gradient); }
.navbar-brand { font-weight: 600; letter-spacing: 0.5px; }
.nav-link { transition: all 0.2s ease-in-out; }
.nav-link.active { font-weight: 600; border-bottom: 2px solid #fff; }
.nav-link:hover { transform: translateY(-2px); }

/* ===========================
   Conteúdo logado
=========================== */
.content { margin-top: 80px; padding: 20px 0; }

/* ===========================
   Botões (globais)
=========================== */
.btn-primary {
  background: var(--gradient);
  border: none;
  font-weight: 500;
  color: #fff;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.btn-primary:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(0,0,0,0.25);
}

/* CTA com gradiente (use: class="btn btn-gradient") */
.btn-gradient {
  background: var(--gradient);
  color: #fff;
  border: none;
  font-weight: 600;
  padding: 0.75rem 1rem;
  border-radius: 10px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.btn-gradient:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.18);
}
.btn-gradient:focus-visible {
  outline: none;
  box-shadow: 0 0 0 0.2rem rgba(60,169,240,0.35);
}
.btn-gradient:disabled {
  opacity: .6;
  filter: saturate(.7);
}

/* (opcional) contorno com gradiente: class="btn btn-outline-gradient" */
.btn-outline-gradient {
  background: #fff;
  color: #3ca9f0;
  border: 2px solid transparent;
  border-image: var(--gradient) 1;
  font-weight: 600;
  padding: 0.65rem 1rem;
  border-radius: 10px;
  transition: background .2s ease, color .2s ease, box-shadow .2s ease;
}
.btn-outline-gradient:hover {
  background: rgba(60,169,240,0.06);
  box-shadow: 0 6px 16px rgba(0,0,0,0.12);
}

/* ===========================
   Cards e Dropdowns
=========================== */
.card {
  border: none;
  border-radius: 12px;
  box-shadow: 0 6px 15px rgba(0,0,0,0.08);
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.15);
}
.dropdown-menu {
  border-radius: 10px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}
.dropdown-item:hover { background-color: #f1f1f1; }

/* ===========================
   Chat (WhatsApp style clean)
=========================== */
.chat-shell {
  height: calc(100vh - 100px); /* ocupa toda a tela menos navbar */
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  display: flex;
}

/* Sidebar */
.chat-list {
  overflow-y: auto;
  background: #f8f9fb;
  height: 100%;
}
.chat-item {
  text-decoration: none;
  color: inherit;
  border-bottom: 1px solid #f0f1f3;
  transition: background .15s ease;
}
.chat-item:hover { background: #eef2f6; }
.chat-item.active {
  background: #e7f3ff;
  border-left: 3px solid #3ca9f0;
}

/* Área principal (conversa) */
.chat-main {
  display: flex;
  flex-direction: column;
  height: 100%;
  flex-grow: 1;
}

/* Cabeçalho */
.chat-header {
  flex-shrink: 0;
  padding: 12px 16px;
  border-bottom: 1px solid #e5e5e5;
  background: #fff;
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Mensagens */
.chat-messages {
  flex-grow: 1;
  display: flex;
  flex-direction: column-reverse; /* estilo WhatsApp */
  padding: 16px;
  gap: 8px;
  overflow-y: auto;
  background: #f5f7fa;
}

/* Bolhas */
.msg-row { display: flex; }
.msg-row.me { justify-content: flex-end; }
.msg-row.other { justify-content: flex-start; }

.msg-bubble {
  max-width: 70%;
  padding: 8px 12px;
  border-radius: 14px;
  box-shadow: 0 1px 2px rgba(0,0,0,.08);
  background: #ffffff;
  word-wrap: break-word;
}
.msg-row.me .msg-bubble {
  background: #dcf8c6;
  border-radius: 14px 14px 4px 14px;
}
.msg-row.other .msg-bubble {
  background: #ffffff;
  border: 1px solid #eef0f2;
  border-radius: 14px 14px 14px 4px;
}
.msg-text { white-space: pre-wrap; }
.msg-meta {
  margin-top: 4px;
  font-size: .75rem;
  color: #6c757d;
  text-align: right;
}

/* Rodapé fixo */
.chat-footer {
  flex-shrink: 0;
  border-top: 1px solid #e5e5e5;
  background: #fff;
  padding: 12px;
}

/* Botão de envio no chat (exclusivo) */
.btn-send {
  background-color: #3ca9f0;
  color: #fff;
  border: none;
  font-weight: 500;
  transition: background .2s ease;
}
.btn-send:hover { background-color: #2e8ad7; }

/* Avatar */
.avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  background: #e9ecef;
  display: inline-block;
}

/* ===========================
   Login Page
=========================== */
.login-wrapper {
  display: flex;
  height: 100vh;
  margin: 0;
  padding: 0;
}
.login-col {
  flex: 0 0 40%;
  background: #f9f9f9;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}
.login-card {
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
  width: 100%;
  max-width: 360px;
  padding: 2rem;
}
.login-card .form-label { color: #333; font-weight: 500; }
.login-card .form-control {
  background: #fdfdfd;
  border: 1px solid #ddd;
  color: #333;
  border-radius: 8px;
}
.login-card .form-control:focus {
  border-color: #3ca9f0;
  box-shadow: 0 0 4px rgba(60, 169, 240, 0.4);
}
.login-bg {
  flex: 0 0 60%;
  background: url("../img/login-bg.jpg") no-repeat center center;
  background-size: cover;
}
 