/* ─────────────────────────────────────────────────────────────
   DOISQ — Shared CSS
   Design System completo usado em todas as páginas
───────────────────────────────────────────────────────────── */

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600;700;800;900&family=Inter:wght@400;500;600&display=swap');

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --navy:        #0d1f3c;
  --navy-light:  #1a3260;
  --orange:      #e8521a;
  --orange-dark: #c94416;
  --white:       #ffffff;
  --gray-bg:     #f0f2f5;
  --gray-light:  #e4e7ec;
  --gray-mid:    #9aa0ac;
  --gray-text:   #555f6d;
  --success:     #16a34a;
  --error:       #dc2626;
  --warning:     #d97706;
  --shadow:      0 4px 20px rgba(0,0,0,0.09);
  --shadow-lg:   0 12px 40px rgba(0,0,0,0.14);
  --radius:      12px;
  --radius-sm:   8px;
  --transition:  0.22s ease;
}

body {
  font-family: 'Inter', sans-serif;
  background: var(--gray-bg);
  color: var(--navy);
  min-height: 100vh;
}

/* ── SCROLLBAR ─────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--gray-light); }
::-webkit-scrollbar-thumb { background: var(--gray-mid); border-radius: 3px; }

/* ── NAVBAR ────────────────────────────────────────────────── */
nav.doisq-nav {
  background: var(--white);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 52px;
  height: 68px;
  border-bottom: 1px solid var(--gray-light);
  position: sticky;
  top: 0;
  z-index: 300;
  box-shadow: 0 2px 10px rgba(0,0,0,0.06);
}
.logo { display: flex; flex-direction: column; line-height: 1; gap: 2px; text-decoration: none; }
.logo-title {
  font-family: 'Montserrat', sans-serif;
  font-weight: 900;
  font-size: 28px;
  letter-spacing: -1.5px;
  color: var(--navy);
}
.logo-title .q { color: var(--orange); }
.logo-sub {
  font-family: 'Montserrat', sans-serif;
  font-size: 8.5px;
  font-weight: 700;
  letter-spacing: 2.2px;
  color: var(--navy);
  text-transform: uppercase;
}
.nav-links { display: flex; gap: 32px; list-style: none; align-items: center; }
.nav-links a {
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  font-size: 12.5px;
  letter-spacing: 0.6px;
  color: var(--navy);
  text-decoration: none;
  text-transform: uppercase;
  transition: color var(--transition);
}
.nav-links a:hover, .nav-links a.nav-active { color: var(--orange); }
.btn-nav-login {
  background: var(--navy) !important;
  color: var(--white) !important;
  padding: 8px 20px !important;
  border-radius: var(--radius-sm) !important;
  transition: background var(--transition) !important;
}
.btn-nav-login:hover { background: var(--orange) !important; }

/* ── BOTÕES ────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  font-size: 13.5px;
  letter-spacing: 0.4px;
  padding: 12px 28px;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: all var(--transition);
  white-space: nowrap;
}
.btn-primary   { background: var(--navy);   color: var(--white); }
.btn-primary:hover { background: var(--navy-light); transform: translateY(-1px); box-shadow: 0 6px 20px rgba(13,31,60,0.3); }
.btn-orange    { background: var(--orange); color: var(--white); }
.btn-orange:hover { background: var(--orange-dark); transform: translateY(-1px); box-shadow: 0 6px 20px rgba(232,82,26,0.35); }
.btn-outline   { background: transparent; color: var(--navy); border: 2px solid var(--navy); }
.btn-outline:hover { background: var(--navy); color: var(--white); }
.btn-ghost     { background: transparent; color: var(--gray-text); border: 1.5px solid var(--gray-light); }
.btn-ghost:hover { border-color: var(--navy); color: var(--navy); }
.btn-sm        { padding: 8px 16px; font-size: 12px; }
.btn-lg        { padding: 16px 36px; font-size: 15px; }
.btn:disabled  { opacity: 0.5; cursor: not-allowed; transform: none !important; }

/* ── CARDS DE IMÓVEL ───────────────────────────────────────── */
.card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.24s cubic-bezier(.34,1.56,.64,1), box-shadow 0.24s;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
  display: block;
}
.card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 40px rgba(0,0,0,0.14);
}
.card-img {
  position: relative;
  height: 190px;
  overflow: hidden;
  background: #c8d0da;
}
.card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}
.card:hover .card-img img { transform: scale(1.08); }
.card-tag {
  position: absolute;
  top: 11px; left: 11px;
  color: var(--white);
  font-family: 'Montserrat', sans-serif;
  font-size: 10px;
  font-weight: 700;
  padding: 4px 9px;
  border-radius: 5px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.card-tag.venda   { background: var(--navy); }
.card-tag.aluguel { background: var(--orange); }
.card-tag.ambos   { background: var(--navy); }
.card-badge {
  position: absolute;
  bottom: 10px; right: 10px;
  background: rgba(255,255,255,0.93);
  border-radius: 6px;
  padding: 4px 8px;
  display: flex; align-items: center; gap: 4px;
  backdrop-filter: blur(4px);
}
.badge-logo {
  font-family: 'Montserrat', sans-serif;
  font-size: 11px; font-weight: 900;
  color: var(--navy); letter-spacing: -0.5px;
}
.badge-logo .q { color: var(--orange); }
.badge-chart { width: 20px; height: 20px; }
.card-body { padding: 15px 17px 17px; }
.card-title {
  font-family: 'Montserrat', sans-serif;
  font-weight: 700; font-size: 14.5px;
  color: var(--navy); margin-bottom: 4px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.card-location {
  font-size: 12px; color: var(--gray-mid);
  margin-bottom: 8px;
  display: flex; align-items: center; gap: 4px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.card-price {
  font-family: 'Montserrat', sans-serif;
  font-weight: 800; font-size: 16.5px;
  color: var(--orange); margin-bottom: 13px;
}
.card-specs {
  display: flex;
  border-top: 1px solid var(--gray-light);
  padding-top: 12px;
}
.spec { display: flex; flex-direction: column; align-items: center; gap: 2px; flex: 1; }
.spec + .spec { border-left: 1px solid var(--gray-light); }
.spec-val { font-family: 'Montserrat', sans-serif; font-weight: 700; font-size: 14px; color: var(--navy); }
.spec-label { font-size: 10.5px; color: var(--gray-mid); text-align: center; }

/* ── SHIMMER (skeleton loading) ────────────────────────────── */
@keyframes shimmer {
  0%   { background-position: -700px 0; }
  100% { background-position: 700px 0; }
}
.skeleton {
  background: linear-gradient(90deg, #e4e7ec 25%, #f5f6f8 50%, #e4e7ec 75%);
  background-size: 700px 100%;
  animation: shimmer 1.4s infinite linear;
  border-radius: 6px;
}
.card-skeleton { pointer-events: none; }
.card-skeleton .card-img { background: #e4e7ec; }
.card-skeleton .sk-title  { height: 16px; width: 75%; margin-bottom: 8px; }
.card-skeleton .sk-loc    { height: 12px; width: 55%; margin-bottom: 8px; }
.card-skeleton .sk-price  { height: 18px; width: 45%; margin-bottom: 14px; }
.card-skeleton .sk-specs  { height: 32px; }

/* ── INPUTS / FORM ─────────────────────────────────────────── */
.form-group { margin-bottom: 20px; }
.form-label {
  display: block;
  font-family: 'Montserrat', sans-serif;
  font-size: 12px; font-weight: 700;
  color: var(--navy);
  margin-bottom: 7px;
  text-transform: uppercase; letter-spacing: 0.5px;
}
.form-input, .form-select, .form-textarea {
  width: 100%;
  border: 1.5px solid var(--gray-light);
  border-radius: var(--radius-sm);
  padding: 11px 14px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: var(--navy);
  background: var(--white);
  transition: border-color var(--transition), box-shadow var(--transition);
  outline: none;
}
.form-input:focus, .form-select:focus, .form-textarea:focus {
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(13,31,60,0.08);
}
.form-input.error, .form-select.error { border-color: var(--error); }
.form-error { font-size: 12px; color: var(--error); margin-top: 4px; }
.form-hint  { font-size: 12px; color: var(--gray-mid); margin-top: 4px; }
.form-textarea { resize: vertical; min-height: 100px; }

/* ── RANGE SLIDER ──────────────────────────────────────────── */
input[type="range"] {
  -webkit-appearance: none;
  width: 100%; height: 4px;
  background: linear-gradient(to right, var(--navy) 62%, var(--gray-light) 62%);
  border-radius: 4px; outline: none; cursor: pointer;
}
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 17px; height: 17px;
  background: var(--navy); border-radius: 50%;
  border: 2.5px solid var(--white);
  box-shadow: 0 2px 8px rgba(0,0,0,0.25);
  cursor: pointer;
}
.checkbox-item {
  display: flex; align-items: center; gap: 9px;
  font-size: 13px; color: var(--gray-text); cursor: pointer;
}
.checkbox-item input[type="checkbox"] {
  width: 15px; height: 15px;
  accent-color: var(--navy); cursor: pointer;
}

/* ── BADGE / PILL ──────────────────────────────────────────── */
.pill {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 10px;
  border-radius: 99px;
  font-size: 11px; font-weight: 600;
  font-family: 'Montserrat', sans-serif;
}
.pill-navy    { background: rgba(13,31,60,0.1); color: var(--navy); }
.pill-orange  { background: rgba(232,82,26,0.12); color: var(--orange); }
.pill-success { background: rgba(22,163,74,0.12); color: var(--success); }
.pill-warn    { background: rgba(217,119,6,0.12);  color: var(--warning); }
.pill-error   { background: rgba(220,38,38,0.12); color: var(--error); }

/* ── TOAST ─────────────────────────────────────────────────── */
#toast-container {
  position: fixed;
  bottom: 28px; right: 28px;
  z-index: 9999;
  display: flex; flex-direction: column; gap: 10px;
}
.toast {
  display: flex; align-items: center; gap: 12px;
  background: var(--navy);
  color: var(--white);
  padding: 14px 20px;
  border-radius: var(--radius-sm);
  box-shadow: 0 8px 28px rgba(0,0,0,0.2);
  font-size: 14px;
  max-width: 360px;
  animation: toastIn 0.3s ease;
}
.toast.success { background: var(--success); }
.toast.error   { background: var(--error); }
.toast.warn    { background: var(--warning); }
@keyframes toastIn {
  from { opacity: 0; transform: translateX(20px); }
  to   { opacity: 1; transform: translateX(0); }
}

/* ── FOOTER ────────────────────────────────────────────────── */
footer.doisq-footer {
  background: var(--navy);
  color: rgba(255,255,255,0.75);
  padding: 48px 52px 32px;
  margin-top: 72px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  max-width: 1300px;
  margin: 0 auto 40px;
}
.footer-brand .logo-title { color: var(--white); font-size: 24px; }
.footer-brand .logo-sub   { color: rgba(255,255,255,0.6); }
.footer-brand p { margin-top: 14px; font-size: 13px; line-height: 1.7; max-width: 260px; }
.footer-col h4 {
  font-family: 'Montserrat', sans-serif;
  font-size: 11px; font-weight: 800;
  letter-spacing: 1.5px; text-transform: uppercase;
  color: var(--white); margin-bottom: 16px;
}
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 10px; }
.footer-col a {
  color: rgba(255,255,255,0.65);
  text-decoration: none; font-size: 13px;
  transition: color var(--transition);
}
.footer-col a:hover { color: var(--orange); }
.footer-bottom {
  max-width: 1300px; margin: 0 auto;
  padding-top: 24px;
  border-top: 1px solid rgba(255,255,255,0.1);
  display: flex; justify-content: space-between; align-items: center;
  font-size: 12px; color: rgba(255,255,255,0.4);
}

/* ── UTILITIES ─────────────────────────────────────────────── */
.text-center { text-align: center; }
.text-orange { color: var(--orange); }
.text-navy   { color: var(--navy); }
.text-muted  { color: var(--gray-mid); }
.mt-8  { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }
.flex  { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.gap-8  { gap: 8px; }
.gap-16 { gap: 16px; }
.w-full { width: 100%; }

/* ── EMPTY STATE ───────────────────────────────────────────── */
.empty-state {
  text-align: center; padding: 60px 20px;
  color: var(--gray-mid);
}
.empty-state svg { margin-bottom: 16px; opacity: 0.4; }
.empty-state h3 {
  font-family: 'Montserrat', sans-serif;
  font-size: 18px; font-weight: 700;
  color: var(--navy); margin-bottom: 8px;
}
.empty-state p { font-size: 14px; }

/* ── RESPONSIVE ────────────────────────────────────────────── */
@media (max-width: 1024px) {
  nav.doisq-nav { padding: 0 24px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  footer.doisq-footer { padding: 40px 24px 28px; }
}
@media (max-width: 768px) {
  nav.doisq-nav { padding: 0 16px; }
  .nav-links { display: none; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .footer-bottom { flex-direction: column; gap: 8px; }
}

/* ─────────────────────────────────────────────────────────────
   CHAT INTERNO — Sistema de Mensagens
───────────────────────────────────────────────────────────── */

/* ── Modal Flutuante (imovel.html) ──────────────────────────── */
.chat-modal {
  position: fixed;
  inset: 0;
  z-index: 1500;
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  padding: 20px;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.25s ease;
}
.chat-modal.open {
  pointer-events: all;
  opacity: 1;
}
.chat-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(13,31,60,0.35);
  backdrop-filter: blur(3px);
  cursor: pointer;
  z-index: 0;
  opacity: 0;
  transition: opacity 0.25s ease;
}
.chat-modal.open .chat-backdrop { opacity: 1; }

.chat-window {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 420px;
  height: 580px;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: 0 24px 64px rgba(0,0,0,0.22);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: translateY(30px) scale(0.97);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.chat-modal.open .chat-window {
  transform: translateY(0) scale(1);
}

/* ── Header ─────────────────────────────────────────────────── */
.chat-header {
  background: var(--navy);
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}
.chat-header-info {
  display: flex;
  align-items: center;
  gap: 12px;
}
.chat-avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--navy-light);
  border: 2px solid rgba(255,255,255,0.2);
  flex-shrink: 0;
}
.chat-outro-nome {
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  font-size: 14px;
  color: var(--white);
  margin-bottom: 2px;
}
.chat-status {
  font-size: 11px;
  color: rgba(255,255,255,0.55);
  display: flex;
  align-items: center;
  gap: 5px;
}
.chat-status::before {
  content: '';
  display: inline-block;
  width: 7px; height: 7px;
  background: #4ade80;
  border-radius: 50%;
  animation: pulse-verde 2s infinite;
}
@keyframes pulse-verde {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}
.chat-close-btn {
  background: rgba(255,255,255,0.1);
  border: none;
  color: var(--white);
  width: 32px; height: 32px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--transition);
  flex-shrink: 0;
}
.chat-close-btn:hover { background: rgba(255,255,255,0.2); }

/* ── Área de mensagens ──────────────────────────────────────── */
.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: #f7f8fc;
  scroll-behavior: smooth;
}
.chat-messages::-webkit-scrollbar { width: 4px; }
.chat-messages::-webkit-scrollbar-thumb { background: var(--gray-mid); }

.chat-empty {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--gray-mid);
  gap: 10px;
  padding: 40px;
}
.chat-empty span { font-size: 36px; }
.chat-empty p {
  font-family: 'Montserrat', sans-serif;
  font-weight: 600;
  font-size: 14px;
}

.chat-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
}
.spinner-sm {
  width: 28px; height: 28px;
  border: 2.5px solid var(--gray-light);
  border-top-color: var(--navy);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

/* ── Bolhas ─────────────────────────────────────────────────── */
.chat-bubble {
  display: flex;
  flex-direction: column;
  max-width: 80%;
  animation: bubbleIn 0.2s ease;
}
@keyframes bubbleIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}
.chat-bubble.propria {
  align-self: flex-end;
  align-items: flex-end;
}
.chat-bubble.outra {
  align-self: flex-start;
  align-items: flex-start;
}
.chat-bubble-text {
  padding: 10px 14px;
  border-radius: 16px;
  font-size: 14px;
  line-height: 1.5;
  word-break: break-word;
}
.chat-bubble.propria .chat-bubble-text {
  background: var(--navy);
  color: var(--white);
  border-bottom-right-radius: 4px;
}
.chat-bubble.outra .chat-bubble-text {
  background: var(--white);
  color: var(--navy);
  border-bottom-left-radius: 4px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.07);
}
.chat-bubble-meta {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 10.5px;
  color: var(--gray-mid);
  margin-top: 3px;
  padding: 0 4px;
}
.chat-lido {
  color: #4ade80;
  font-size: 11px;
}

/* ── Aviso de telefone ──────────────────────────────────────── */
.chat-aviso-telefone {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #fef2f2;
  border-top: 1px solid #fee2e2;
  border-bottom: 1px solid #fee2e2;
  color: var(--error);
  padding: 10px 16px;
  font-size: 12.5px;
  line-height: 1.45;
  flex-shrink: 0;

  /* Oculto por padrão */
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.3s ease, opacity 0.3s ease, padding 0.3s ease;
  padding-top: 0;
  padding-bottom: 0;
}
.chat-aviso-telefone.visible {
  max-height: 80px;
  opacity: 1;
  padding: 10px 16px;
}
.chat-aviso-telefone svg { flex-shrink: 0; }
.chat-aviso-telefone span { flex: 1; }
.chat-aviso-fechar {
  background: none;
  border: none;
  color: var(--error);
  cursor: pointer;
  font-size: 16px;
  padding: 0 4px;
  flex-shrink: 0;
  opacity: 0.7;
  transition: opacity var(--transition);
}
.chat-aviso-fechar:hover { opacity: 1; }

/* ── Input de mensagem ──────────────────────────────────────── */
.chat-input-area {
  border-top: 1px solid var(--gray-light);
  padding: 12px 14px 10px;
  background: var(--white);
  flex-shrink: 0;
}
.chat-input-wrap {
  display: flex;
  align-items: flex-end;
  gap: 10px;
}
.chat-input {
  flex: 1;
  border: 1.5px solid var(--gray-light);
  border-radius: 20px;
  padding: 10px 16px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: var(--navy);
  background: #f7f8fc;
  outline: none;
  resize: none;
  max-height: 120px;
  min-height: 40px;
  overflow-y: auto;
  line-height: 1.4;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.chat-input:focus {
  border-color: var(--navy);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(13,31,60,0.06);
}
.chat-input.input-shake {
  animation: shake 0.5s ease;
  border-color: var(--error) !important;
}
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20%      { transform: translateX(-6px); }
  40%      { transform: translateX(6px); }
  60%      { transform: translateX(-4px); }
  80%      { transform: translateX(4px); }
}
.chat-send-btn {
  width: 40px; height: 40px;
  background: var(--navy);
  color: var(--white);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background var(--transition), transform 0.15s;
}
.chat-send-btn:hover { background: var(--orange); transform: scale(1.06); }
.chat-send-btn:disabled { opacity: 0.4; cursor: not-allowed; transform: none; }
.chat-input-footer {
  display: flex;
  justify-content: space-between;
  margin-top: 6px;
  padding: 0 4px;
}
.chat-char-count {
  font-size: 10.5px;
  color: var(--gray-mid);
}
.chat-hint {
  font-size: 10.5px;
  color: var(--gray-light);
}

/* ── Botão iniciar chat (imovel.html) ───────────────────────── */
.btn-chat {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 14px;
  background: linear-gradient(135deg, var(--navy) 0%, #1a3260 100%);
  color: var(--white);
  border: none;
  border-radius: var(--radius-sm);
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: all var(--transition);
  margin-bottom: 12px;
  letter-spacing: 0.3px;
}
.btn-chat:hover {
  background: linear-gradient(135deg, var(--orange) 0%, var(--orange-dark) 100%);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(232,82,26,0.3);
}
.btn-chat svg { flex-shrink: 0; }

/* ── Painel — Layout de chat ─────────────────────────────────── */
.painel-chat-layout {
  display: grid;
  grid-template-columns: 300px 1fr;
  height: calc(100vh - 200px);
  min-height: 500px;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

/* Lista de conversas */
.chat-lista-conversas {
  border-right: 1px solid var(--gray-light);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.chat-lista-header {
  padding: 18px 20px;
  border-bottom: 1px solid var(--gray-light);
  font-family: 'Montserrat', sans-serif;
  font-weight: 800;
  font-size: 15px;
  color: var(--navy);
  flex-shrink: 0;
}
.chat-lista-items {
  flex: 1;
  overflow-y: auto;
}
.chat-conversa-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--gray-light);
  cursor: pointer;
  transition: background var(--transition);
}
.chat-conversa-item:hover { background: var(--gray-bg); }
.chat-conversa-item.ativa { background: rgba(13,31,60,0.05); }
.chat-conversa-avatar {
  width: 44px; height: 44px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  background: var(--gray-light);
}
.chat-conversa-info { flex: 1; min-width: 0; }
.chat-conversa-nome {
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  font-size: 13px;
  color: var(--navy);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 2px;
}
.chat-conversa-preview {
  font-size: 12px;
  color: var(--gray-mid);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.chat-conversa-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 5px;
  flex-shrink: 0;
}
.chat-conversa-hora {
  font-size: 10.5px;
  color: var(--gray-mid);
}
.chat-badge-nao-lida {
  background: var(--orange);
  color: var(--white);
  font-size: 10px;
  font-weight: 700;
  font-family: 'Montserrat', sans-serif;
  border-radius: 99px;
  padding: 2px 6px;
  min-width: 18px;
  text-align: center;
}

/* Área de chat no painel */
.chat-area-painel {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.chat-area-header {
  background: var(--navy);
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}
.painel-chat-avatar {
  width: 38px; height: 38px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--navy-light);
  border: 2px solid rgba(255,255,255,0.2);
}
.painel-chat-nome {
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  font-size: 14px;
  color: var(--white);
}
.painel-chat-imovel {
  font-size: 11px;
  color: rgba(255,255,255,0.55);
}

/* Input no painel reutiliza os estilos do modal */
.chat-input-painel {
  composes: chat-input;
}

/* Estado vazio de conversas */
.chat-sem-conversa {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--gray-mid);
  gap: 14px;
  padding: 40px;
  text-align: center;
}
.chat-sem-conversa span { font-size: 48px; }
.chat-sem-conversa h3 {
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  font-size: 16px;
  color: var(--navy);
}
.chat-sem-conversa p { font-size: 13px; line-height: 1.6; }

/* ── Responsive do chat ──────────────────────────────────────── */
@media (max-width: 900px) {
  .chat-window {
    max-width: 100%;
    height: 90vh;
  }
  .chat-modal {
    padding: 0;
    align-items: flex-end;
  }
  .chat-window {
    border-radius: var(--radius) var(--radius) 0 0;
  }
  .painel-chat-layout {
    grid-template-columns: 1fr;
    height: auto;
  }
  .chat-lista-conversas {
    border-right: none;
    border-bottom: 1px solid var(--gray-light);
    max-height: 280px;
  }
}
