[hidden]{display:none !important;}

:root{
  --navy-900:#081530; --navy-800:#0B1E3D; --navy-700:#142B57; --navy-600:#1D3A6E;
  --orange:#FF6A1A; --orange-light:#FFA655;
  --white:#FFFFFF; --gray-text:#C9D2E0;
  --font-display:'Montserrat', sans-serif; --font-body:'Inter', sans-serif;
  --radius:12px;
}
*{box-sizing:border-box;}
html{font-size:19px;}
body{margin:0;background:var(--navy-900);color:var(--white);font-family:var(--font-body);}
h1,h2,h3{font-family:var(--font-display);margin:0 0 .3em;}
p{margin:0;color:var(--gray-text);}
button{font-family:var(--font-body);}
::selection{background:var(--orange);color:var(--white);}

.logo-mark{width:36px;height:36px;border-radius:9px;background:var(--orange);display:flex;align-items:center;justify-content:center;font-family:var(--font-display);font-weight:800;font-size:.8rem;flex-shrink:0;}
.logo-text{font-family:var(--font-display);font-weight:600;}
.logo-text strong{color:var(--orange);}

/* =========== BUTTONS =========== */
.btn{display:inline-flex;align-items:center;gap:8px;justify-content:center;padding:11px 20px;border-radius:9px;font-family:var(--font-display);font-weight:700;font-size:.85rem;border:1px solid transparent;cursor:pointer;transition:.15s;}
.btn-primary{background:var(--orange);color:var(--white);}
.btn-primary:hover{background:var(--orange-light);}
.btn-ghost{background:transparent;border-color:var(--navy-600);color:var(--gray-text);}
.btn-ghost:hover{border-color:var(--orange);color:var(--orange);}
.btn-danger{background:transparent;border-color:#F87171;color:#F87171;}
.btn-danger:hover{background:#F87171;color:var(--white);}
.btn-sm{padding:7px 14px;font-size:.78rem;}
.btn-block{width:100%;}
.btn:disabled{opacity:.6;cursor:default;transform:none;}

/* =========== LOGIN =========== */
.login-screen{min-height:100vh;display:flex;align-items:center;justify-content:center;background:radial-gradient(600px 400px at 80% 0%, rgba(255,106,26,.15), transparent 60%), var(--navy-800); padding:20px;}
.login-card{background:var(--navy-700);border:1px solid rgba(255,255,255,.08);border-radius:var(--radius);padding:36px;width:100%;max-width:380px;display:flex;flex-direction:column;gap:16px;}
.login-logo{display:flex;align-items:center;gap:10px;}
.login-sub{font-size:.85rem;margin-bottom:6px;}
.login-error{color:#F87171;font-size:.85rem;}
.login-feedback{color:#86EFAC;font-size:.85rem;}
.link-btn{background:none;border:0;color:var(--gray-text);font-size:.8rem;text-decoration:underline;cursor:pointer;padding:0;text-align:center;}
.link-btn:hover{color:var(--orange-light);}
.form-row{display:flex;flex-direction:column;gap:5px;}
.form-row label{font-size:.75rem;color:var(--gray-text);}
.form-row input,.form-row select,.form-row textarea{
  background:var(--navy-800);border:1px solid var(--navy-600);color:var(--white);
  padding:10px 12px;border-radius:8px;font-size:.9rem;font-family:var(--font-body);resize:vertical;
}

/* =========== APP SHELL (menu no topo) =========== */
.app-shell{display:flex;flex-direction:column;min-height:100vh;}
.topbar{
  display:flex;align-items:center;gap:22px;flex-wrap:wrap;row-gap:8px;
  background:var(--navy-800);border-bottom:1px solid rgba(255,255,255,.06);
  padding:10px 24px;position:sticky;top:0;z-index:80;
}
.topbar-brand{display:flex;align-items:center;gap:10px;flex-shrink:0;}
.topnav{display:flex;align-items:center;gap:2px;flex:1;flex-wrap:wrap;row-gap:4px;}
.nav-item{
  display:flex;align-items:center;gap:8px;text-align:left;white-space:nowrap;
  background:transparent;border:0;color:var(--gray-text);
  padding:9px 12px;border-radius:8px;font-size:.85rem;cursor:pointer;transition:.15s;
}
.nav-item:hover{background:var(--navy-700);color:var(--white);}
.nav-item.active{background:var(--orange);color:var(--white);}
.topnav-item{flex-shrink:0;}
.topnav-group{position:relative;flex-shrink:0;}
.topnav-trigger{
  display:flex;align-items:center;gap:6px;white-space:nowrap;
  background:transparent;border:0;color:var(--gray-text);
  padding:9px 12px;border-radius:8px;font-size:.85rem;cursor:pointer;transition:.15s;
}
.topnav-trigger:hover{background:var(--navy-700);color:var(--white);}
.topnav-trigger.group-active{background:var(--navy-700);color:var(--orange-light);}
.topnav-trigger .caret{font-size:.65rem;opacity:.7;}
.topnav-dropdown{
  display:none;position:absolute;top:100%;left:0;margin-top:6px;min-width:210px;
  background:var(--navy-700);border:1px solid rgba(255,255,255,.1);border-radius:10px;
  padding:6px;flex-direction:column;gap:2px;box-shadow:0 14px 34px -10px rgba(0,0,0,.55);z-index:90;
}
.topnav-dropdown.open{display:flex;}
.topnav-dropdown .nav-item{padding:9px 12px;}
.topbar-right{display:flex;align-items:center;gap:14px;margin-left:auto;flex-shrink:0;}
.topbar-right p{font-size:.75rem;max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}

.main-area{flex:1;padding:32px 36px;max-width:100%;overflow-x:auto;}
.view-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:24px;gap:16px;flex-wrap:wrap;}
.view-head h1{font-size:1.5rem;}
.view-head p{font-size:.88rem;}
.view-head-badge{color:var(--orange-light);font-weight:600;}
.badge-oculto{font-size:.72rem;color:var(--gray-text);background:var(--navy-800);border:1px solid var(--navy-600);padding:3px 8px;border-radius:20px;white-space:nowrap;}
.badge-ok{font-size:.72rem;color:#16a766;background:rgba(22,167,102,.12);border:1px solid rgba(22,167,102,.35);padding:3px 8px;border-radius:20px;white-space:nowrap;}

.proprietario-picker{display:flex;gap:10px;align-items:center;flex-wrap:wrap;}
.proprietario-picker select{flex:1;min-width:180px;}
.proprietario-novo{background:var(--navy-800);border:1px solid var(--navy-600);border-radius:10px;padding:12px;}
.proprietario-novo-grid{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin:6px 0;}
.proprietario-novo-grid input{background:var(--navy-700);border:1px solid var(--navy-600);color:var(--white);padding:9px 11px;border-radius:8px;font-size:.85rem;font-family:var(--font-body);}
@media (max-width:640px){.proprietario-novo-grid{grid-template-columns:1fr;}}

.filters-bar{display:flex;gap:10px;flex-wrap:wrap;align-items:center;margin-bottom:16px;}
.filters-bar select,.filters-bar input{background:var(--navy-800);border:1px solid var(--navy-600);color:var(--white);padding:8px 10px;border-radius:8px;font-size:.85rem;font-family:var(--font-body);}
.filters-bar-label{display:flex;align-items:center;gap:6px;font-size:.78rem;color:var(--gray-text);}

/* =========== STATS =========== */
.stats-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:16px;margin-bottom:28px;}
.stat-card{background:var(--navy-700);border:1px solid rgba(255,255,255,.06);border-radius:var(--radius);padding:20px;}
.stat-card .stat-value{font-family:var(--font-display);font-size:1.9rem;font-weight:800;color:var(--orange);}
.stat-card .stat-label{font-size:.8rem;color:var(--gray-text);}

/* =========== PANEL / TABLE =========== */
.panel{background:var(--navy-700);border:1px solid rgba(255,255,255,.06);border-radius:var(--radius);padding:20px;}
.panel-head{margin-bottom:14px;}
.panel-head h2{font-size:1.05rem;}
.table-wrap{background:var(--navy-700);border:1px solid rgba(255,255,255,.06);border-radius:var(--radius);overflow-x:auto;}
table{width:100%;border-collapse:collapse;font-size:.86rem;}
th{text-align:left;padding:12px 16px;color:var(--gray-text);font-size:.72rem;text-transform:uppercase;letter-spacing:.05em;border-bottom:1px solid rgba(255,255,255,.08);white-space:nowrap;}
td{padding:12px 16px;border-bottom:1px solid rgba(255,255,255,.05);white-space:nowrap;}
tr:last-child td{border-bottom:0;}
tr:hover td{background:rgba(255,255,255,.02);}
.table-empty{padding:30px;text-align:center;color:var(--gray-text);}

.status-pill{display:inline-block;padding:4px 10px;border-radius:999px;font-size:.72rem;font-weight:600;background:var(--navy-600);color:var(--gray-text);}
.status-novo{background:#1D3A6E;color:#93C5FD;}
.status-em_atendimento{background:#5B3A1D;color:#FDBA74;}
.status-qualificado,.status-visita_agendada{background:#1D3A6E;color:#67E8F9;}
.status-proposta{background:#4C1D5B;color:#E9A8FF;}
.status-fechado{background:#14532D;color:#86EFAC;}
.status-perdido,.status-cancelada{background:#4B1D1D;color:#FCA5A5;}
.status-disponivel{background:#14532D;color:#86EFAC;}
.status-reservado{background:#5B3A1D;color:#FDBA74;}
.status-vendido,.status-alugado{background:#1D3A6E;color:#93C5FD;}
.status-inativo{background:#3a3a3a;color:#aaa;}

select.status-select{background:var(--navy-800);color:var(--white);border:1px solid var(--navy-600);border-radius:6px;padding:5px 8px;font-size:.78rem;}

/* =========== MODAL =========== */
.modal-overlay{position:fixed;inset:0;background:rgba(4,10,24,.72);backdrop-filter:blur(3px);display:none;align-items:center;justify-content:center;z-index:100;padding:20px;}
.modal-overlay.open{display:flex;}
.modal{background:var(--navy-800);border:1px solid rgba(255,255,255,.08);border-radius:var(--radius);max-width:620px;width:100%;max-height:88vh;overflow-y:auto;position:relative;padding:30px;}
.modal.modal-wide{max-width:900px;}
.modal-close{position:absolute;top:14px;right:14px;background:var(--navy-700);border:0;color:var(--white);width:32px;height:32px;border-radius:50%;cursor:pointer;}
.modal h2{margin-bottom:18px;}
.modal-subtitle{color:var(--gray-text);font-size:.85rem;margin:-12px 0 18px;}
.modal-form{display:grid;grid-template-columns:1fr 1fr;gap:14px;}
.modal-form .full{grid-column:1/-1;}
.modal-actions{grid-column:1/-1;display:flex;justify-content:flex-end;gap:10px;margin-top:6px;}
.check-row{display:flex;align-items:center;gap:8px;font-size:.85rem;color:var(--gray-text);}

/* =========== GERADOR DE DOCUMENTOS (fieldsets de qualificação) =========== */
.doc-fieldset{grid-column:1/-1;border:1px solid rgba(255,255,255,.1);border-radius:10px;padding:16px 16px 4px;display:grid;grid-template-columns:1fr 1fr;gap:14px;margin-bottom:4px;background:rgba(255,255,255,.02);}
.doc-fieldset legend{padding:0 8px;font-weight:600;color:var(--orange);font-size:.9rem;}
.doc-fieldset .full{grid-column:1/-1;}
.doc-modelos-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(260px,1fr));gap:16px;}
.doc-modelo-card{background:var(--navy-800);border:1px solid rgba(255,255,255,.08);border-radius:var(--radius);padding:20px;display:flex;flex-direction:column;gap:10px;}
.doc-modelo-card h3{font-size:1rem;margin:0;display:flex;align-items:center;gap:8px;flex-wrap:wrap;}
.doc-modelo-card p{color:var(--gray-text);font-size:.83rem;flex:1;margin:0;}
.doc-modelo-badge{font-size:.68rem;font-weight:600;text-transform:uppercase;letter-spacing:.03em;color:var(--orange);border:1px solid var(--orange);border-radius:20px;padding:2px 9px;}
.doc-modelo-actions{display:flex;flex-wrap:wrap;gap:8px;}
.doc-upload-label{cursor:pointer;}
.doc-modelos-ajuda{color:var(--gray-text);font-size:.83rem;grid-column:1/-1;margin:0 0 4px;}
.doc-modelos-ajuda code{background:rgba(255,255,255,.08);padding:1px 6px;border-radius:4px;}

/* =========== TOAST =========== */
.toast{position:fixed;bottom:24px;right:24px;background:var(--navy-700);border:1px solid var(--orange);color:var(--white);padding:14px 20px;border-radius:9px;font-size:.85rem;z-index:200;box-shadow:0 10px 30px -6px rgba(0,0,0,.5);}
.toast.err{border-color:#F87171;}

/* =========== RESPONSIVE =========== */
@media (max-width:900px){
  .topbar{flex-wrap:wrap;row-gap:8px;padding:10px 14px;}
  .topnav{order:3;width:100%;}
  .topbar-right p{display:none;}
  .main-area{padding:20px;}
  .modal-form{grid-template-columns:1fr;}
}

/* Logo real (substitui o antigo placeholder "GM") */
.logo-mark-img{
  width:40px;height:40px;object-fit:contain;flex-shrink:0;
}

/* =========== EQUIPE / DEPOIMENTOS: avatar em miniatura na tabela =========== */
.table-avatar{width:40px;height:40px;border-radius:50%;object-fit:cover;background:var(--navy-600);display:block;}
.table-avatar-placeholder{
  width:40px;height:40px;border-radius:50%;background:var(--orange);
  display:flex;align-items:center;justify-content:center;color:var(--white);
  font-family:var(--font-display);font-weight:700;font-size:.75rem;
}

/* =========== GALERIA DE FOTOS DO HERO =========== */
.hero-gallery{display:grid;grid-template-columns:repeat(auto-fill,minmax(220px,1fr));gap:18px;}
.hero-gallery-card{
  background:var(--navy-700);border:1px solid rgba(255,255,255,.06);border-radius:var(--radius);
  overflow:hidden;
}
.hero-gallery-thumb{height:140px;background:var(--navy-800);}
.hero-gallery-thumb img{width:100%;height:100%;object-fit:cover;}
.hero-gallery-body{padding:12px 14px;display:flex;flex-direction:column;gap:8px;}
.hero-gallery-body .check-row{font-size:.8rem;}

/* =========== UPLOAD DE FOTO NO FORM =========== */
.upload-row{display:flex;flex-direction:column;gap:8px;}
.upload-preview{width:80px;height:80px;border-radius:12px;object-fit:cover;background:var(--navy-800);}

/* =========== UPLOAD DE MÚLTIPLAS FOTOS (IMÓVEIS) =========== */
.fotos-grid{display:flex;flex-wrap:wrap;gap:10px;margin-bottom:8px;}
.foto-thumb{position:relative;width:90px;height:90px;border-radius:10px;overflow:hidden;background:var(--navy-800);}
.foto-thumb img{width:100%;height:100%;object-fit:cover;display:block;}
.foto-thumb.pendente{outline:2px solid var(--laranja,#ff7a1a);}
.foto-remove{position:absolute;top:2px;right:2px;width:20px;height:20px;border:none;border-radius:50%;
  background:rgba(0,0,0,.65);color:#fff;font-size:.85rem;line-height:1;cursor:pointer;}
.foto-remove:hover{background:#c0392b;}

/* =========== FOTO PRINCIPAL (CAPA) DO IMÓVEL =========== */
.foto-thumb.capa{outline:3px solid #ffc107;}
.foto-capa-btn{position:absolute;top:2px;left:2px;width:20px;height:20px;border:none;border-radius:50%;
  background:rgba(0,0,0,.65);color:#ffc107;font-size:.85rem;line-height:1;cursor:pointer;}
.foto-capa-btn:hover{background:#ffc107;color:#1a1a1a;}
.foto-capa-badge{position:absolute;bottom:2px;left:2px;right:2px;background:#ffc107;color:#1a1a1a;
  font-size:.6rem;font-weight:700;text-align:center;border-radius:4px;padding:1px 0;}

/* =========== MINIATURA DE FOTO NA LISTA DE IMÓVEIS =========== */
.linha-foto-thumb{width:48px;height:48px;border-radius:8px;object-fit:cover;display:block;background:var(--navy-800);}
.linha-foto-vazia{display:flex;align-items:center;justify-content:center;font-size:1.2rem;}

/* =========== BOTÃO "VER O SITE" NA SIDEBAR =========== */
.btn-ver-site{
  display:flex; align-items:center; justify-content:center; gap:6px;
  margin:0 8px 16px; padding:10px 12px; border-radius:10px;
  background:var(--orange); color:var(--white); text-decoration:none;
  font-weight:600; font-size:.85rem; text-align:center;
  transition:background .15s;
}
.btn-ver-site:hover{background:var(--orange-light);}

/* =========== FUNIL DE VENDAS (KANBAN) =========== */
.kanban-board{display:flex;gap:14px;overflow-x:auto;padding-bottom:12px;}
.kanban-col{flex:0 0 250px;background:var(--navy-800);border-radius:var(--radius);padding:12px;display:flex;flex-direction:column;gap:10px;max-height:calc(100vh - 220px);}
.kanban-col-head{display:flex;align-items:center;justify-content:space-between;font-family:var(--font-display);font-weight:700;font-size:.8rem;padding:0 2px 8px;border-bottom:1px solid var(--navy-600);}
.kanban-col-count{background:var(--navy-600);color:var(--gray-text);border-radius:20px;padding:1px 9px;font-size:.72rem;}
.kanban-cards{display:flex;flex-direction:column;gap:8px;overflow-y:auto;}
.kanban-card{background:var(--navy-700);border:1px solid rgba(255,255,255,.06);border-radius:9px;padding:10px 12px;display:flex;flex-direction:column;gap:6px;}
.kanban-card strong{font-size:.85rem;}
.kanban-card small{color:var(--gray-text);font-size:.72rem;}
.kanban-card-corretor{display:inline-block;align-self:flex-start;background:var(--orange);color:var(--white);font-size:.65rem;font-weight:700;border-radius:6px;padding:2px 7px;}
.kanban-empty{color:var(--gray-text);font-size:.75rem;text-align:center;padding:14px 4px;}

/* =========== RELATÓRIOS =========== */
.relatorios-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(230px,1fr));gap:14px;}
.relatorio-card{background:var(--navy-800);border:1px solid rgba(255,255,255,.06);border-radius:var(--radius);padding:18px;display:flex;flex-direction:column;gap:10px;text-align:left;color:var(--white);cursor:pointer;transition:.15s;}
.relatorio-card:hover{border-color:var(--orange);}
.relatorio-card strong{font-family:var(--font-display);font-size:.9rem;}
.relatorio-card span{color:var(--gray-text);font-size:.78rem;}
.relatorio-card.destaque{border-color:var(--orange);}

/* =========== TUTORIAL =========== */
.tutorial-content{max-width:820px;display:flex;flex-direction:column;gap:8px;}
.tutorial-content details{background:var(--navy-800);border-radius:10px;padding:14px 16px;}
.tutorial-content summary{cursor:pointer;font-family:var(--font-display);font-weight:700;font-size:.88rem;}
.tutorial-content details p{margin-top:10px;font-size:.85rem;line-height:1.55;}

/* =========== MINI BOT DE AJUDA =========== */
.bot-toggle{position:fixed;bottom:22px;right:22px;width:54px;height:54px;border-radius:50%;background:var(--orange);
  color:var(--white);border:none;font-size:1.4rem;cursor:pointer;box-shadow:0 6px 18px rgba(0,0,0,.35);z-index:60;}
.bot-toggle:hover{background:var(--orange-light);}
.bot-panel{position:fixed;bottom:86px;right:22px;width:320px;max-width:calc(100vw - 32px);height:420px;max-height:calc(100vh - 120px);
  background:var(--navy-700);border:1px solid rgba(255,255,255,.08);border-radius:var(--radius);
  display:flex;flex-direction:column;overflow:hidden;box-shadow:0 12px 32px rgba(0,0,0,.45);z-index:60;}
.bot-panel-head{display:flex;align-items:center;justify-content:space-between;padding:12px 14px;background:var(--navy-800);border-bottom:1px solid var(--navy-600);}
.bot-close{background:none;border:none;color:var(--gray-text);font-size:1rem;cursor:pointer;}
.bot-messages{flex:1;overflow-y:auto;padding:12px 14px;display:flex;flex-direction:column;gap:10px;}
.bot-msg{font-size:.82rem;line-height:1.5;padding:8px 11px;border-radius:9px;max-width:88%;}
.bot-msg.bot{background:var(--navy-800);align-self:flex-start;}
.bot-msg.user{background:var(--orange);color:var(--white);align-self:flex-end;}
.bot-form{display:flex;gap:8px;padding:10px 12px;border-top:1px solid var(--navy-600);}
.bot-form input{flex:1;background:var(--navy-800);border:1px solid var(--navy-600);border-radius:8px;color:var(--white);padding:9px 11px;font-size:.82rem;}
.bot-form input:focus{outline:none;border-color:var(--orange);}

/* =========== HISTÓRICO DE INTERAÇÕES (LEAD) =========== */
.interacoes-lista{display:flex;flex-direction:column;gap:8px;max-height:220px;overflow-y:auto;margin-bottom:6px;}
.interacao-item{background:var(--navy-800);border-radius:8px;padding:8px 12px;}
.interacao-meta{font-size:.7rem;color:var(--gray-text);margin-bottom:3px;text-transform:capitalize;}
.interacao-texto{font-size:.85rem;}
.visita-feedback{cursor:help;opacity:.85;}

/* =========== VISTORIAS =========== */
.vistoria-item-linha{background:var(--navy-800);border-radius:8px;padding:8px 12px;margin-bottom:6px;font-size:.85rem;}
.status-otimo{background:#14532D;color:#86EFAC;}
.status-bom{background:#1D3A6E;color:#93C5FD;}
.status-regular{background:#7C5A11;color:#FCD34D;}
.status-ruim{background:#7F1D1D;color:#FCA5A5;}
.status-concluida{background:#14532D;color:#86EFAC;}
.status-em_andamento{background:#7C5A11;color:#FCD34D;}
.status-cancelada{background:#7F1D1D;color:#FCA5A5;}

/* =========== DOCUMENTOS E ANEXOS =========== */
.documentos-lista{display:flex;flex-direction:column;gap:6px;margin-bottom:8px;}
.documento-item{display:flex;align-items:center;justify-content:space-between;gap:10px;background:var(--navy-800);border-radius:8px;padding:7px 12px;font-size:.82rem;}
.documento-item a{color:var(--orange-light);text-decoration:none;}
.documento-item a:hover{text-decoration:underline;}

/* =========== AUDITORIA =========== */
.auditoria-json{background:var(--navy-800);border-radius:8px;padding:10px 12px;font-size:.72rem;line-height:1.5;overflow-x:auto;white-space:pre-wrap;word-break:break-word;color:var(--gray-text);}

/* =========== CONFIGURAÇÃO DA MARCA D'ÁGUA =========== */
.marca-dagua-config{display:flex;flex-direction:column;gap:10px;margin-top:8px;}
.marca-dagua-opcoes{display:flex;gap:20px;flex-wrap:wrap;}
.marca-dagua-opcoes label{display:flex;flex-direction:column;gap:4px;font-size:.78rem;color:var(--gray-text);}
.marca-dagua-opcoes select,.marca-dagua-opcoes input[type="range"]{width:190px;}

/* Oferta Ativa — ações agrupadas (pegar de novo / devolver) */
.btn-group-inline{display:flex;gap:8px;flex-wrap:wrap;}

/* =========================================================
   IMÓVEIS — cards (substitui a antiga tabela)
   ========================================================= */
.empty-state{padding:40px;text-align:center;color:var(--gray-text);background:var(--navy-700);border:1px solid rgba(255,255,255,.06);border-radius:var(--radius);}
.imoveis-cards{display:grid;grid-template-columns:1fr;gap:14px;}
.imovel-card{
  display:flex;gap:16px;background:var(--navy-700);border:1px solid rgba(255,255,255,.06);
  border-radius:var(--radius);padding:14px;transition:border-color .15s ease;
}
.imovel-card:hover{border-color:rgba(255,106,26,.35);}
.imovel-card-photo{
  position:relative;flex-shrink:0;width:160px;height:120px;border-radius:10px;overflow:hidden;
  background:var(--navy-800);display:flex;align-items:center;justify-content:center;
}
.imovel-card-photo img{width:100%;height:100%;object-fit:cover;}
.imovel-card-photo-vazia{font-size:2rem;opacity:.5;}
.imovel-card-flag{
  position:absolute;top:8px;left:8px;background:var(--orange);color:var(--white);
  font-size:.68rem;font-weight:700;padding:3px 8px;border-radius:999px;
}
.imovel-card-body{flex:1;min-width:0;display:flex;flex-direction:column;gap:10px;}
.imovel-card-top{display:flex;justify-content:space-between;align-items:flex-start;gap:12px;}
.imovel-card-heading{min-width:0;}
.imovel-card-codigo{font-size:.72rem;color:var(--gray-text);text-transform:uppercase;letter-spacing:.04em;}
.imovel-card-titulo{margin:2px 0 4px;font-size:1.02rem;font-family:var(--font-display);}
.imovel-card-loc{margin:0;font-size:.82rem;color:var(--gray-text);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.imovel-card-badges{display:flex;flex-wrap:wrap;gap:6px;}
.badge-mini{background:var(--navy-600);color:var(--gray-text);font-size:.72rem;padding:3px 10px;border-radius:999px;}
.imovel-card-footer{display:flex;justify-content:space-between;align-items:flex-end;gap:12px;flex-wrap:wrap;margin-top:auto;}
.imovel-card-preco{font-family:var(--font-display);font-size:1.15rem;color:var(--orange);}
.imovel-card-preco-sep{color:var(--gray-text);font-weight:400;}
.imovel-card-meta{display:block;font-size:.72rem;color:var(--gray-text);margin-top:2px;}
.imovel-card-actions{display:flex;flex-wrap:wrap;gap:6px;justify-content:flex-end;}
.imoveis-cards-more{display:flex;justify-content:center;padding:10px 0;}

@media (max-width: 720px){
  .imovel-card{flex-direction:column;}
  .imovel-card-photo{width:100%;height:180px;}
  .imovel-card-actions{justify-content:flex-start;}
}

/* Status de contratos */
.status-ativo{background:#14532D;color:#86EFAC;}
.status-encerrado{background:#3a3a3a;color:#aaa;}
.status-cancelado{background:#4B1D1D;color:#FCA5A5;}
.status-inadimplente{background:#7F1D1D;color:#FCA5A5;}

/* Status de vistorias */
.status-agendada{background:#1D3A6E;color:#93C5FD;}

/* Pessoas — card com avatar de iniciais */
.pessoa-card{align-items:flex-start;}
.pessoa-card-avatar{
  flex-shrink:0;width:52px;height:52px;border-radius:50%;background:var(--navy-600);
  display:flex;align-items:center;justify-content:center;font-family:var(--font-display);
  font-weight:700;font-size:1rem;color:var(--orange-light);
}
.pessoas-cards .imovel-card-body{padding-left:2px;}

/* Financeiro — grupos por dia de repasse */
.cobrancas-grupo{margin-bottom:32px;}
.cobrancas-grupo-head{display:flex;justify-content:space-between;align-items:baseline;flex-wrap:wrap;gap:8px;margin-bottom:12px;padding-bottom:8px;border-bottom:1px solid rgba(255,255,255,.08);}
.cobrancas-grupo-head h2{margin:0;font-size:1.05rem;color:var(--orange-light);}

/* Financeiro — sub-abas Locações / Vendas */
.financeiro-tabs{display:flex;gap:8px;margin-bottom:20px;border-bottom:1px solid rgba(255,255,255,.08);}
.financeiro-tab{
  background:none;border:none;color:var(--gray-text);font-family:var(--font-display);font-weight:700;
  font-size:.88rem;padding:10px 4px;cursor:pointer;border-bottom:2px solid transparent;margin-bottom:-1px;
}
.financeiro-tab:hover{color:var(--white);}
.financeiro-tab.active{color:var(--orange);border-bottom-color:var(--orange);}
.financeiro-painel{}

/* Destaque do 1º aluguel (comissão de fechamento do corretor) */
.imovel-card-destaque{border-color:rgba(255,166,85,.4);background:linear-gradient(180deg, rgba(255,106,26,.07), var(--navy-700) 60%);}
.badge-mini-destaque{background:rgba(255,106,26,.22);color:var(--orange-light);font-weight:700;}

/* Editor inline da comissão do 1º aluguel */
.comissao-editavel{align-items:center;}
.comissao-editor{display:inline-flex;align-items:center;gap:6px;font-size:.78rem;color:var(--gray-text);background:var(--navy-800);border:1px solid var(--navy-600);border-radius:999px;padding:4px 8px 4px 12px;}
.comissao-pct-input{width:52px;background:transparent;border:none;border-bottom:1px solid var(--navy-600);color:var(--white);font-size:.85rem;padding:2px 2px;text-align:right;}
.comissao-pct-input:focus{outline:none;border-color:var(--orange);}
.comissao-pct-valor{color:var(--orange-light);font-weight:700;margin-left:2px;}

/* Resumo em cards de estatística (usado em Vendas e Lucro do mês) */
.about-stats{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:14px;margin-bottom:28px;}
.about-card{background:var(--navy-700);border:1px solid rgba(255,255,255,.06);border-radius:var(--radius);padding:18px 20px;display:flex;flex-direction:column;gap:4px;}
.about-card strong{font-family:var(--font-display);font-size:1.35rem;color:var(--orange);}
.about-card span{font-size:.78rem;color:var(--gray-text);}
.about-card-total{background:linear-gradient(135deg, rgba(255,106,26,.18), var(--navy-700));border-color:rgba(255,106,26,.4);}
.about-card-total strong{color:var(--orange-light);font-size:1.55rem;}

.portal-section-title-crm{font-size:1rem;color:var(--orange-light);margin:28px 0 12px;}

/* Seletor de mês (Lucro do mês) */
#lucroMes{background:var(--navy-800);color:var(--white);border:1px solid var(--navy-600);border-radius:8px;padding:9px 14px;font-size:.9rem;}

/* Editor de comissão (líquido recebido + % + status pendente/pago) */
.comissao-editor-bloco{display:flex;flex-direction:column;gap:8px;background:var(--navy-800);border:1px solid var(--navy-600);border-radius:10px;padding:10px 12px;margin:10px 0;}
.comissao-editor-linha{display:flex;align-items:center;flex-wrap:wrap;gap:8px;}
.comissao-editor-linha label{font-size:.72rem;color:var(--gray-text);white-space:nowrap;}
.comissao-liquido-input{width:110px;background:var(--navy-900);border:1px solid var(--navy-600);color:var(--white);font-size:.85rem;border-radius:6px;padding:5px 8px;}
.comissao-liquido-input:focus,.comissao-editor-bloco .comissao-pct-input:focus{outline:none;border-color:var(--orange);}
.comissao-editor-bloco .comissao-pct-input{width:56px;background:var(--navy-900);border:1px solid var(--navy-600);color:var(--white);font-size:.85rem;border-radius:6px;padding:5px 6px;text-align:right;}
.comissao-editor-bloco .comissao-pct-valor{color:var(--orange-light);font-weight:700;margin-left:auto;font-size:.9rem;}
.comissao-status-toggle{white-space:nowrap;}

/* Nota explicativa da geração automática de cobranças */
.financeiro-auto-nota{font-size:.8rem;color:var(--gray-text);margin:-8px 0 18px;padding:8px 14px;background:var(--navy-800);border:1px solid var(--navy-600);border-radius:8px;}

/* Ajustes (descontos/acréscimos) lançados numa cobrança */
.ajustes-lista{display:flex;flex-direction:column;gap:6px;margin:10px 0;}
.ajuste-item{display:flex;align-items:flex-start;justify-content:space-between;gap:10px;background:var(--navy-800);border-left:3px solid var(--gray-text);border-radius:6px;padding:8px 10px;font-size:.82rem;}
.ajuste-item.ajuste-acrescimo{border-left-color:#4caf7d;}
.ajuste-item.ajuste-desconto{border-left-color:#e0555f;}
.ajuste-item-texto{display:flex;flex-direction:column;gap:2px;color:var(--white);}
.ajuste-meta{font-size:.7rem;color:var(--gray-text);}
.ajuste-excluir{background:none;border:none;color:var(--gray-text);cursor:pointer;font-size:.85rem;line-height:1;padding:2px 4px;}
.ajuste-excluir:hover{color:#e0555f;}
