/* =========================================================================
   CASAPĒ — Layout do painel interno e componentes
   ========================================================================= */

/* ---- Tamanho padrão de ícones inline (svg do helper icon()) ---- */
.btn svg, .seg button svg, .ai-btn svg, .copy-btn svg,
.intake-head svg, .chip svg, .module-card .go svg, .lp-hero .loc svg {
  width: 16px; height: 16px; flex: none; vertical-align: -3px;
}
.seg button svg { margin-right: 6px; }

/* ---- Topbar ---- */
.topbar {
  position: sticky; top: 0; z-index: 50;
  background: rgba(251,250,246,.82);
  backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.topbar-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 16px 24px;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.brand-lockup { display: flex; align-items: baseline; gap: 12px; }
.brand-lockup .wordmark { font-size: 1.55rem; }
.brand-lockup .sub {
  font-size: .66rem; letter-spacing: .26em; text-transform: uppercase;
  color: var(--ink-faint); font-weight: 600;
}
.topnav { display: flex; gap: 4px; align-items: center; }
.topnav a {
  padding: 9px 16px; border-radius: var(--r-pill);
  font-size: .88rem; font-weight: 500; color: var(--ink-soft);
  transition: background .15s, color .15s;
}
.topnav a:hover { background: var(--bg-soft); color: var(--ink); }
.topnav a.active { background: var(--brand); color: var(--c-cream); }

@media (max-width: 820px) {
  .topnav a span { display: none; }
  .brand-lockup .sub { display: none; }
}

/* ---- Container ---- */
.wrap-page { max-width: var(--maxw); margin: 0 auto; padding: 40px 24px 96px; }

/* ---- Cabeçalho de página de módulo ---- */
.page-head { margin-bottom: 32px; }
.page-head .eyebrow { display: block; margin-bottom: 10px; }
.page-head h1 { font-family: var(--font-display); font-size: clamp(2.1rem, 4vw, 3rem); }
.page-head p { color: var(--ink-soft); max-width: 60ch; margin: 10px 0 0; }

/* =========================================================================
   DASHBOARD (index)
   ========================================================================= */
.hero {
  position: relative; overflow: hidden;
  border-radius: var(--r-lg);
  background:
    radial-gradient(1200px 400px at 80% -20%, rgba(160,94,51,.18), transparent 60%),
    linear-gradient(135deg, var(--c-espresso), #20140d 70%);
  color: var(--c-cream);
  padding: 56px 48px;
  box-shadow: var(--shadow);
}
.hero .eyebrow { color: var(--c-copper); }
.hero h1 { font-family: var(--font-display); font-size: clamp(2.4rem, 5vw, 3.8rem); margin: 14px 0 14px; line-height: 1.02; }
.hero p { max-width: 56ch; color: rgba(237,231,207,.82); font-weight: 300; font-size: 1.05rem; }
.hero .accent-line { width: 64px; height: 2px; background: var(--c-copper); margin: 0 0 4px; }

.modules { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 28px; }
@media (max-width: 900px) { .modules { grid-template-columns: 1fr; } }

.module-card {
  display: flex; flex-direction: column;
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
  transition: transform .25s var(--ease), box-shadow .25s, border-color .25s;
  min-height: 280px;
}
.module-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: var(--line-strong); }
.module-card .num {
  font-family: var(--font-display); font-size: 2.6rem; line-height: 1;
  color: var(--accent); opacity: .85;
}
.module-icon {
  width: 46px; height: 46px; border-radius: 12px;
  display: grid; place-items: center; margin: 16px 0 18px;
  background: var(--bg-soft); border: 1px solid var(--line);
}
.module-icon svg { width: 24px; height: 24px; stroke: var(--accent); }
.module-card h3 { font-family: var(--font-display); font-size: 1.5rem; }
.module-card p { color: var(--ink-soft); font-size: .92rem; margin: 8px 0 0; flex: 1; }
.module-card .go { margin-top: 20px; }

/* ---- Faixa de paleta da marca ---- */
.palette-strip { display: flex; height: 10px; border-radius: 999px; overflow: hidden; margin-top: 14px; }
.palette-strip span { flex: 1; }

/* =========================================================================
   INTAKE PRAEDIUM (componente compartilhado)
   ========================================================================= */
.intake {
  border-radius: var(--r-lg);
  border: 1px solid var(--line-strong);
  background:
    linear-gradient(180deg, var(--surface-2), var(--surface));
  padding: 22px 24px;
  margin-bottom: 28px;
  box-shadow: var(--shadow-sm);
}
.intake-head { display: flex; align-items: center; gap: 12px; margin-bottom: 4px; }
.intake-head .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px rgba(160,94,51,.16); }
.intake-head h3 { font-family: var(--font-display); font-size: 1.35rem; }
.intake .lead { color: var(--ink-soft); font-size: .9rem; margin: 0 0 16px; }

.seg {
  display: inline-flex; padding: 4px; gap: 4px;
  background: var(--bg-soft); border: 1px solid var(--line); border-radius: var(--r-pill);
  margin-bottom: 16px;
}
.seg button {
  border: none; background: transparent; cursor: pointer;
  padding: 8px 18px; border-radius: var(--r-pill);
  font-weight: 600; font-size: .85rem; color: var(--ink-soft);
  transition: background .15s, color .15s;
}
.seg button.active { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-sm); }

.praedium-row { display: flex; gap: 10px; align-items: flex-end; }
.praedium-row .field { flex: 1; margin-bottom: 0; }
@media (max-width: 640px){ .praedium-row { flex-direction: column; align-items: stretch; } }

.import-status {
  margin-top: 14px; font-size: .85rem; display: none;
  align-items: center; gap: 10px; color: var(--ink-soft);
}
.import-status.show { display: flex; }
.spinner {
  width: 16px; height: 16px; border-radius: 50%;
  border: 2px solid var(--line-strong); border-top-color: var(--accent);
  animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* =========================================================================
   LAYOUT BUILDER (form + preview)
   ========================================================================= */
.builder { display: grid; grid-template-columns: 1fr 1fr; gap: 26px; align-items: start; }
@media (max-width: 1000px) { .builder { grid-template-columns: 1fr; } }

.panel { padding: 26px; }
.panel h2.section-title {
  font-family: var(--font-display); font-size: 1.4rem; margin-bottom: 4px;
}
.panel .section-sub { color: var(--ink-soft); font-size: .86rem; margin: 0 0 18px; }

.preview-col { position: sticky; top: 92px; }
.preview-frame {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--shadow);
}
.preview-bar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 16px; border-bottom: 1px solid var(--line); background: var(--surface-2);
}
.preview-bar .dots { display: flex; gap: 6px; }
.preview-bar .dots i { width: 10px; height: 10px; border-radius: 50%; background: var(--line-strong); }
.preview-bar .label { font-size: .76rem; color: var(--ink-faint); font-weight: 600; letter-spacing: .04em; }
.preview-scroll { max-height: 72vh; overflow-y: auto; }

.with-ai { display: flex; gap: 8px; align-items: flex-end; }
.with-ai .field { flex: 1; margin-bottom: 0; }
.ai-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 11px 14px; border-radius: var(--r-sm);
  border: 1px solid var(--line-strong); background: var(--surface);
  cursor: pointer; font-size: .8rem; font-weight: 600; color: var(--accent);
  white-space: nowrap; transition: background .15s, border-color .15s;
}
.ai-btn:hover { background: var(--bg-soft); border-color: var(--accent); }
.ai-btn svg { width: 15px; height: 15px; }

.actions-bar {
  display: flex; gap: 10px; flex-wrap: wrap;
  margin-top: 8px; padding-top: 20px; border-top: 1px solid var(--line);
}

/* lista de diferenciais / itens dinâmicos */
.tag-input { display: flex; gap: 8px; }
.tag-input .input { flex: 1; }
.tag-pool { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }

/* A landing page gerada (escopo .lp) usa o LP_CSS injetado por assets/js/landing.js
   — mesma folha de estilo da exportação. Aqui mantemos só o placeholder vazio. */
.empty-preview { padding: 60px 30px; text-align: center; color: var(--ink-faint); }
.empty-preview svg { width: 46px; height: 46px; stroke: var(--line-strong); margin-bottom: 12px; }

/* =========================================================================
   PROPOSTA (mapeamento)
   ========================================================================= */
.imovel-pick {
  display: flex; gap: 14px; padding: 14px; border: 1px solid var(--line);
  border-radius: var(--r); margin-bottom: 12px; background: var(--surface); align-items: center;
  transition: border-color .15s, box-shadow .15s;
}
.imovel-pick:hover { border-color: var(--line-strong); }
.imovel-pick .thumb { width: 76px; height: 60px; border-radius: 8px; object-fit: cover; background: var(--bg-soft); flex: none; }
.imovel-pick .meta { flex: 1; min-width: 0; }
.imovel-pick .meta b { font-weight: 600; font-size: .95rem; }
.imovel-pick .meta .sub { font-size: .8rem; color: var(--ink-faint); }
.match-badge {
  font-family: var(--font-display); font-size: 1.3rem; color: var(--accent);
  display: flex; flex-direction: column; align-items: center; line-height: 1; flex: none;
}
.match-badge span { font-family: var(--font-body); font-size: .6rem; text-transform: uppercase; letter-spacing: .1em; color: var(--ink-faint); }

/* Minha conta */
.conta-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 24px; align-items: start; }
@media (max-width: 900px) { .conta-grid { grid-template-columns: 1fr; } }
.conta-avatar { display: flex; align-items: center; gap: 18px; margin-bottom: 20px; }
.ava-lg { width: 84px; height: 84px; border-radius: 50%; overflow: hidden; flex: none; background: var(--accent); color: #fff; display: grid; place-items: center; font-family: var(--font-display); font-weight: 700; font-size: 2rem; }
.ava-lg img { width: 100%; height: 100%; object-fit: cover; }
.conta-avatar-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.conta-avatar-actions .hint { flex-basis: 100%; }
.hist-row { display: flex; align-items: flex-start; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.hist-row:last-child { border-bottom: 0; }
.hist-dot { width: 8px; height: 8px; border-radius: 50%; margin-top: 6px; flex: none; background: var(--ink-faint); }
.hist-dot.tone-ok { background: #2e7d52; }
.hist-dot.tone-danger { background: var(--c-red); }
.hist-dot.tone-info { background: var(--c-navy, #00456B); }
.hist-ico { flex: none; width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; background: var(--bg-soft); color: var(--accent); }
.hist-ico svg { width: 16px; height: 16px; }
a.hist-link { text-decoration: none; color: inherit; border-radius: 8px; transition: background .12s; margin: 0 -8px; padding-left: 8px; padding-right: 8px; }
a.hist-link:hover { background: var(--bg-soft); }
a.hist-link .hist-when { color: var(--accent); font-weight: 600; }
.hist-body { flex: 1; display: flex; flex-direction: column; line-height: 1.3; min-width: 0; }
.hist-body b { font-size: .86rem; font-weight: 600; }
.hist-body span { font-size: .8rem; color: var(--ink-faint); }
.hist-when { font-size: .74rem; color: var(--ink-faint); white-space: nowrap; flex: none; }

/* Meus projetos (grade de cartões) */
.proj-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 18px; }
.proj-card { display: flex; flex-direction: column; gap: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 20px; transition: border-color .15s, box-shadow .15s; }
.proj-card:hover { border-color: var(--line-strong); box-shadow: 0 14px 40px rgba(61,43,30,.08); }
.proj-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.proj-type { display: inline-flex; align-items: center; gap: 6px; font-size: .68rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.proj-type svg { width: 15px; height: 15px; }
.proj-date { font-size: .72rem; color: var(--ink-faint); }
.proj-title { font-family: var(--font-display); font-size: 1.3rem; line-height: 1.15; margin: 4px 0 0; }
.proj-sum { font-size: .86rem; color: var(--ink-soft); margin: 0; min-height: 1.2em; }
.proj-owner { font-size: .74rem; color: var(--ink-faint); margin: 0; }
.proj-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.proj-actions .btn svg { width: 14px; height: 14px; vertical-align: -2px; margin-right: 4px; }

/* Documento de proposta (gerado) — escopo .prop · estética editorial airy */
.prop { background: #f3eede; color: #3D2B1E; padding: clamp(32px, 6vw, 72px) clamp(28px, 6vw, 64px); --p-accent: #A05E33; --p-soft: #6e5b49; --p-faint: #a3947f; --p-line: #ddd1b6; }
.prop-cover { display: flex; justify-content: space-between; align-items: flex-start; padding-bottom: 22px; border-bottom: 1px solid var(--p-line); }
.prop-brand { display: flex; flex-direction: column; gap: 4px; }
.prop-mark { font-family: var(--font-display); font-size: 1.6rem; letter-spacing: .26em; text-transform: uppercase; color: #3D2B1E; }
.prop-kicker { font-size: .62rem; letter-spacing: .3em; text-transform: uppercase; color: var(--p-faint); }
.prop-meta { text-align: right; font-size: .72rem; line-height: 1.7; letter-spacing: .04em; color: var(--p-faint); }
/* Hero da proposta */
.prop-hero { padding: clamp(48px, 9vw, 110px) 0 clamp(36px, 6vw, 64px); max-width: 70ch; }
.prop-eyebrow { display: block; font-size: .64rem; font-weight: 600; letter-spacing: .32em; text-transform: uppercase; color: var(--p-accent); margin-bottom: 20px; }
.prop-hero-title { font-family: var(--font-display); font-weight: 400; font-size: clamp(2.6rem, 7vw, 5rem); line-height: 1.02; letter-spacing: -.02em; margin: 0 0 24px; color: #3D2B1E; }
.prop-lede { color: var(--p-soft); font-weight: 300; font-size: clamp(1rem, 1.6vw, 1.18rem); line-height: 1.9; white-space: pre-wrap; margin: 0 0 28px; }
.prop-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.prop-chip { font-size: .64rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--p-soft); border: 1px solid var(--p-line); border-radius: 999px; padding: 8px 15px; }
/* Lista de itens */
.prop-list { display: flex; flex-direction: column; gap: clamp(40px, 7vw, 84px); padding: clamp(20px, 4vw, 40px) 0; }
.prop-item { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(24px, 4vw, 56px); align-items: center; }
.prop-item:nth-child(even) { grid-template-columns: 1fr 1.1fr; }
.prop-item:nth-child(even) .prop-item-media { order: 2; }
.prop-item-media { display: flex; flex-direction: column; gap: 8px; }
.prop-photo { width: 100%; aspect-ratio: 4/3; background: #e6ded0 center/cover no-repeat; border-radius: 4px; }
.prop-thumbs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.prop-thumb { aspect-ratio: 1/1; background: #e6ded0 center/cover no-repeat; border-radius: 3px; }
.prop-item-top { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; }
.prop-rank { font-family: var(--font-display); font-size: clamp(2rem, 4vw, 3rem); line-height: 1; color: var(--p-faint); }
.prop-match { text-align: right; line-height: 1; flex: none; }
.prop-match b { font-family: var(--font-display); font-weight: 400; font-size: clamp(2.2rem, 4.5vw, 3.4rem); color: var(--p-accent); }
.prop-match b i { font-style: normal; font-size: .5em; }
.prop-match span { display: block; margin-top: 4px; font-size: .58rem; letter-spacing: .22em; text-transform: uppercase; color: var(--p-faint); }
.prop-name { font-family: var(--font-display); font-weight: 400; font-size: clamp(1.5rem, 2.6vw, 2.2rem); line-height: 1.12; margin: 14px 0 6px; color: #3D2B1E; }
.prop-price { font-family: var(--font-display); font-size: 1.25rem; color: var(--p-accent); margin-bottom: 16px; }
.prop-specs { list-style: none; margin: 0 0 16px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 18px; }
.prop-specs li { position: relative; padding-left: 16px; font-size: .82rem; color: var(--p-soft); }
.prop-specs li::before { content: ''; position: absolute; left: 0; top: 7px; width: 5px; height: 5px; border: 1px solid var(--p-accent); transform: rotate(45deg); }
.prop-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 18px; }
.prop-tag { font-size: .68rem; color: var(--p-soft); background: #e9e1cb; border-radius: 999px; padding: 5px 12px; }
.prop-video { position: relative; width: 100%; aspect-ratio: 16/9; background: #1a110c; border-radius: 4px; overflow: hidden; margin-top: 8px; }
.prop-video iframe, .prop-video video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; object-fit: cover; }
.prop-why { position: relative; border-top: 1px solid var(--p-line); padding-top: 16px; }
.prop-comment { position: relative; }
.prop-del { position: absolute; top: 8px; right: 0; width: 24px; height: 24px; border: 0; border-radius: 50%; background: rgba(139,22,16,.12); color: #8B1610; cursor: pointer; font-size: .78rem; line-height: 1; display: flex; align-items: center; justify-content: center; opacity: 0; transition: opacity .15s, background .15s; }
.prop-why:hover .prop-del, .prop-comment:hover .prop-del { opacity: 1; }
.prop-del:hover { background: #8B1610; color: #fff; }
@media print { .prop-del { display: none !important; } }
.prop-why-label { display: block; font-size: .6rem; font-weight: 600; letter-spacing: .22em; text-transform: uppercase; color: var(--p-accent); margin-bottom: 8px; }
.prop-why p { margin: 0; font-size: .92rem; line-height: 1.75; color: var(--p-soft); font-weight: 300; }
/* Rodapé */
.prop-foot { margin-top: clamp(40px, 7vw, 80px); padding-top: 28px; border-top: 1px solid var(--p-line); display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; }
.prop-foot-msg { font-family: var(--font-display); font-size: clamp(1.3rem, 2.4vw, 2rem); line-height: 1.2; color: #3D2B1E; }
.prop-hl { color: var(--p-accent); font-style: italic; }
/* edição inline na prévia da proposta */
.prop [contenteditable] { cursor: text; border-radius: 3px; transition: outline-color .15s, background .15s; outline: 1px dashed transparent; outline-offset: 3px; }
.prop [contenteditable]:hover { outline-color: rgba(160,94,51,.4); }
.prop [contenteditable]:focus { outline: 2px solid var(--p-accent); background: rgba(160,94,51,.05); }
@media print { .prop [contenteditable] { outline: none !important; background: none !important; } }
/* ações por imóvel no catálogo */
.imovel-actions { display: flex; gap: 6px; flex: none; }
/* checagem de indispensáveis/desejáveis por imóvel (faltantes em vermelho) */
.prop-checks { margin: 0 0 16px; display: flex; flex-direction: column; gap: 9px; }
.prop-checkrow { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.prop-checkrow-label { font-size: .58rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--p-faint); margin-right: 4px; flex: none; }
.prop-chks { display: flex; flex-wrap: wrap; gap: 6px; }
.prop-chk { font-size: .7rem; border-radius: 999px; padding: 4px 11px; border: 1px solid var(--p-line); color: var(--p-soft); background: #fff; white-space: nowrap; }
.prop-chk.ok { border-color: rgba(6,36,26,.28); color: #0c2a20; }
.prop-chk.miss { border-color: #8B1610; color: #fff; background: #8B1610; font-weight: 600; }
.prop-chk.opt { color: var(--p-faint); border-style: dashed; }
/* comentário do corretor por imóvel */
.prop-comment { border-top: 1px solid var(--p-line); margin-top: 14px; padding-top: 12px; }
.prop-comment-label { display: block; font-size: .6rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--p-accent); margin-bottom: 6px; }
.prop-comment-text { margin: 0; font-size: .9rem; line-height: 1.6; color: var(--p-soft); min-height: 1.2em; }
.prop-comment-text:empty::before { content: attr(data-ph); color: var(--p-faint); font-style: italic; }
/* CTA da proposta (falar com corretor + agendar visita) */
.prop-cta { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-top: 36px; padding-top: 30px; border-top: 1px solid var(--p-line); }
.prop-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; background: var(--p-accent); color: #fff; border: 1px solid var(--p-accent); border-radius: 999px; padding: 14px 30px; font-family: var(--font-body); font-weight: 600; font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; text-decoration: none; cursor: pointer; transition: transform .2s, background .2s; }
.prop-btn:hover { transform: translateY(-2px); background: #8a4f2b; }
.prop-btn.ghost { background: transparent; color: var(--p-accent); }
.prop-btn.ghost:hover { background: rgba(160,94,51,.08); }
/* modal de agendamento da proposta */
.prop-schedule { position: fixed; inset: 0; z-index: 420; background: rgba(15,9,6,.6); backdrop-filter: blur(3px); display: none; align-items: center; justify-content: center; padding: 20px; }
.prop-schedule.open { display: flex; }
.prop-schedule-card { position: relative; background: #fbf9f4; color: #3D2B1E; width: 100%; max-width: 440px; border-radius: 16px; padding: clamp(24px,4vw,38px); box-shadow: 0 40px 100px rgba(0,0,0,.45); max-height: 92vh; overflow: auto; }
.prop-schedule-card .prop-eyebrow { display: block; margin-bottom: 6px; }
.prop-schedule-card h3 { font-family: var(--font-display); font-weight: 400; font-size: 1.8rem; margin: 0 0 4px; }
.prop-schedule-card > p { color: var(--p-soft); font-size: .9rem; margin: 0 0 18px; }
.prop-schedule-card .field { margin-bottom: 12px; }
.prop-schedule-card .prop-btn { width: 100%; margin-top: 4px; }
.prop-schedule-x { position: absolute; top: 12px; right: 14px; background: none; border: 0; font-size: 1.2rem; cursor: pointer; color: var(--p-soft); line-height: 1; }
.prop-schedule-status { margin-top: 12px; font-size: .86rem; text-align: center; color: var(--p-soft); }
.prop-schedule-status.ok { color: #2e7d52; }
@media print { .prop-schedule { display: none !important; } .prop-comment:has(.prop-comment-text:empty) { display: none !important; } }

/* ===================== Proposta no formato MICROSITE ===================== */
.prop-site { padding: 0; background: #f3eede; }
.prop-site .prop-hl { color: var(--p-accent); font-style: italic; }
/* NAV */
.prop-nav { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px clamp(20px,4vw,48px); background: rgba(36,23,18,.96); backdrop-filter: blur(8px); }
.prop-nav-mark { font-family: var(--font-display); font-size: 1.35rem; letter-spacing: .28em; text-transform: uppercase; color: #fff; text-decoration: none; }
.prop-nav-links { display: flex; gap: clamp(12px,2vw,28px); }
.prop-nav-links a { color: rgba(255,255,255,.9); text-decoration: none; font-size: .64rem; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; }
.prop-nav-links a:hover { opacity: .6; }
.prop-nav-cta { color: #fff; border: 1px solid rgba(255,255,255,.55); border-radius: 999px; padding: 9px 18px; font-size: .58rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; text-decoration: none; white-space: nowrap; }
.prop-nav-cta:hover { background: #fff; color: #3D2B1E; }
@media (max-width: 760px) { .prop-nav-links { display: none; } }
/* HERO com foto */
.prop-hero2 { position: relative; min-height: 60vh; display: flex; flex-direction: column; justify-content: flex-end; gap: 14px; padding: clamp(40px,8vw,90px) clamp(24px,5vw,72px); color: #fff; background: #241712 center/cover no-repeat; overflow: hidden; }
.prop-hero2-scrim { position: absolute; inset: 0; background: linear-gradient(180deg,rgba(20,12,8,.35),rgba(20,12,8,.08) 40%,rgba(20,12,8,.8)); }
.prop-hero2-inner, .prop-hero2-meta { position: relative; z-index: 2; }
.prop-hero2-inner { max-width: 780px; }
.prop-hero2-eyebrow { display: block; font-size: .64rem; font-weight: 600; letter-spacing: .3em; text-transform: uppercase; color: #e3b487; margin-bottom: 14px; }
.prop-hero2-title { font-family: var(--font-display); font-weight: 400; font-size: clamp(2.6rem,7vw,5.2rem); line-height: 1.02; letter-spacing: -.02em; margin: 0; }
.prop-hero2-lede { margin: 18px 0 0; font-weight: 300; font-size: clamp(1rem,1.6vw,1.18rem); line-height: 1.8; max-width: 60ch; opacity: .95; }
.prop-hero2 .prop-chips { margin-top: 22px; }
.prop-hero2 .prop-chip { border-color: rgba(255,255,255,.4); color: #fff; }
.prop-hero2-meta { font-size: .64rem; letter-spacing: .18em; text-transform: uppercase; opacity: .8; margin-top: 6px; }
/* SEÇÃO IMÓVEIS */
.prop-imoveis { padding: clamp(56px,9vw,110px) clamp(24px,6vw,64px); max-width: 1200px; margin: 0 auto; }
.prop-sec-head { text-align: center; margin-bottom: clamp(36px,5vw,60px); }
.prop-sec-head .prop-eyebrow { display: block; margin-bottom: 14px; }
.prop-sec-head h2 { font-family: var(--font-display); font-weight: 400; font-size: clamp(2rem,4vw,3.2rem); color: #3D2B1E; }
.prop-sec-head-dark h2 { color: #EDE7CF; }
.prop-imoveis .prop-list { padding: 0; }
/* controles do item (arrastar/excluir) */
.prop-item { position: relative; }
.prop-item-ctrl { position: absolute; top: -12px; right: 0; z-index: 6; display: flex; gap: 6px; opacity: 0; transition: opacity .15s; }
.prop-item:hover .prop-item-ctrl { opacity: 1; }
.prop-item-drag { display: inline-flex; align-items: center; gap: 4px; background: var(--p-accent); color: #fff; font-size: .58rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; padding: 5px 11px; border-radius: 999px; cursor: grab; }
.prop-item-del { width: 26px; height: 26px; border: 0; border-radius: 50%; background: #8B1610; color: #fff; cursor: pointer; font-size: .72rem; }
.prop-item.prop-dragging { opacity: .4; }
/* botão de recorte/zoom por foto */
.prop-photo, .prop-thumb { position: relative; }
.prop-crop { position: absolute; top: 8px; right: 8px; z-index: 4; display: inline-flex; align-items: center; gap: 5px; border: 0; cursor: pointer; background: rgba(20,12,8,.78); color: #fff; font-family: var(--font-body); font-weight: 600; font-size: .68rem; padding: 6px 11px; border-radius: 999px; opacity: 0; transition: opacity .15s, background .15s; }
.prop-photo:hover .prop-crop, .prop-thumb:hover .prop-crop, .prop-hero2:hover .prop-crop-hero { opacity: 1; }
.prop-crop:hover { background: var(--p-accent); }
.prop-crop-sm { padding: 4px 8px; font-size: .7rem; top: 5px; right: 5px; }
.prop-crop-hero { position: absolute; top: 14px; right: 16px; z-index: 5; opacity: 0; }
@media print { .prop-crop { display: none !important; } }
/* endereço no rodapé (coluna da marca, à esquerda) */
.prop-footer-addr { display: block; margin-top: 14px; font-size: .8rem; line-height: 1.55; color: rgba(237,231,207,.6); max-width: 30ch; }
/* botão flutuante destacado (falar com corretor / agendar) */
.prop-fab { position: fixed; right: 22px; bottom: 22px; z-index: 410; display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
.prop-fab-menu { display: flex; flex-direction: column; gap: 8px; opacity: 0; transform: translateY(10px) scale(.96); pointer-events: none; transition: opacity .2s, transform .2s; transform-origin: bottom right; }
.prop-fab.open .prop-fab-menu { opacity: 1; transform: none; pointer-events: auto; }
.prop-fab-opt { display: block; background: #fff; color: #3D2B1E; border: 1px solid #e8e1d4; cursor: pointer; padding: 13px 22px; border-radius: 14px; font-family: var(--font-body); font-weight: 600; font-size: .86rem; text-decoration: none; text-align: center; box-shadow: 0 10px 26px rgba(0,0,0,.18); transition: transform .15s, border-color .15s, color .15s; }
.prop-fab-opt:hover { transform: translateX(-3px); border-color: var(--p-accent); color: var(--p-accent); }
.prop-fab-btn { position: relative; display: inline-flex; align-items: center; gap: 9px; background: linear-gradient(135deg,#c0743f,#8a4f2b); color: #fff; border: 0; cursor: pointer; padding: 16px 28px; border-radius: 999px; font-family: var(--font-body); font-weight: 700; font-size: .95rem; box-shadow: 0 16px 40px rgba(160,94,51,.5); animation: propfabpulse 2.6s ease-in-out infinite; }
.prop-fab-btn::before { content: ''; position: absolute; inset: 0; border-radius: 999px; border: 2px solid rgba(192,116,63,.7); animation: propfabring 2.6s ease-out infinite; pointer-events: none; }
.prop-fab-btn:hover { transform: translateY(-3px) scale(1.03); }
.prop-fab-ico { display: inline-block; animation: propfabsparkle 2.2s ease-in-out infinite; }
@keyframes propfabpulse { 0%,100% { box-shadow: 0 16px 40px rgba(160,94,51,.45); } 50% { box-shadow: 0 16px 54px rgba(160,94,51,.85); } }
@keyframes propfabring { 0% { transform: scale(1); opacity: .7; } 100% { transform: scale(1.45); opacity: 0; } }
@keyframes propfabsparkle { 0%,100% { transform: rotate(0) scale(1); } 50% { transform: rotate(20deg) scale(1.25); } }
@media print { .prop-fab { display: none !important; } }
/* ATENDIMENTO EXCLUSIVO (verde) */
.prop-atend { text-align: center; padding: clamp(64px,10vw,140px) clamp(24px,6vw,40px); color: #EDE7CF; background: radial-gradient(900px 420px at 50% -10%, rgba(160,94,51,.4), transparent 60%), #06241A; }
.prop-atend .prop-eyebrow { display: block; margin-bottom: 16px; color: #e3b487; }
.prop-atend h2 { font-family: var(--font-display); font-weight: 400; font-size: clamp(2rem,4.6vw,3.4rem); line-height: 1.08; color: #EDE7CF; }
.prop-atend > p { max-width: 48ch; margin: 16px auto 30px; font-weight: 300; opacity: .86; line-height: 1.8; }
.prop-atend .prop-cta { margin: 0; padding: 0; border: 0; }
.prop-btn.ghost-light { background: transparent; color: #fff; border-color: rgba(255,255,255,.6); }
.prop-btn.ghost-light:hover { background: rgba(255,255,255,.12); color: #fff; }
.prop-broker { display: inline-flex; align-items: center; gap: 12px; margin-top: 34px; }
.prop-broker-av { width: 46px; height: 46px; border-radius: 50%; background: var(--p-accent); display: grid; place-items: center; color: #fff; font-family: var(--font-display); font-size: 1.2rem; }
.prop-broker-info { text-align: left; display: flex; flex-direction: column; }
.prop-broker-info small { opacity: .7; font-size: .78rem; }
/* A CASAPĒ (vídeo institucional) */
.prop-instit { padding: clamp(56px,9vw,120px) 0 0; background: #241712; }
.prop-instit .prop-sec-head { padding: 0 clamp(24px,6vw,64px); }
.prop-instit-video { position: relative; width: 100%; aspect-ratio: 16/9; background: #1a110c; overflow: hidden; }
.prop-instit-video iframe, .prop-instit-video video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; object-fit: cover; }
.prop-instit-ph { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: rgba(237,231,207,.5); font-family: var(--font-display); font-size: clamp(1.2rem,2.4vw,1.8rem); }
.prop-vid-edit { position: absolute; top: 14px; left: 50%; transform: translateX(-50%); z-index: 3; background: rgba(20,12,8,.8); color: #fff; border: 0; border-radius: 999px; padding: 9px 16px; font-size: .7rem; font-weight: 600; cursor: pointer; }
.prop-vid-edit:hover { background: var(--p-accent); }
/* FOOTER */
.prop-footer { position: relative; background: #241712; color: rgba(237,231,207,.66); padding: clamp(48px,7vw,80px) clamp(24px,6vw,64px) 34px; }
.prop-footer-wave { position: absolute; top: -1px; left: 0; width: 100%; height: clamp(30px,4vw,56px); transform: translateY(-99%); display: block; }
.prop-footer-wave path { fill: #241712; }
.prop-footer-cols { display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: clamp(24px,5vw,56px); padding-bottom: 32px; border-bottom: 1px solid rgba(237,231,207,.16); }
.prop-footer-brand .prop-mark { display: block; color: #EDE7CF; font-size: 1.6rem; margin-bottom: 12px; }
.prop-footer-brand p { margin: 0; max-width: 32ch; line-height: 1.7; color: rgba(237,231,207,.6); }
.prop-footer-col h4 { font-size: .64rem; font-weight: 700; letter-spacing: .22em; text-transform: uppercase; color: #e3b487; margin: 0 0 14px; }
.prop-footer-col a, .prop-footer-col span { display: block; color: rgba(237,231,207,.78); text-decoration: none; margin-bottom: 8px; line-height: 1.5; }
.prop-footer-col a:hover { color: #fff; }
.prop-footer-base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; padding-top: 22px; font-size: .72rem; color: rgba(237,231,207,.5); }
@media (max-width: 720px) { .prop-footer-cols { grid-template-columns: 1fr; } }
/* ===== IMPRESSÃO: documento limpo e elegante (sem cara de site escuro) ===== */
@page { margin: 14mm 13mm; }
@media print {
  /* garante que fotos, cores e tags (vermelho/cobre) sejam impressas */
  .prop-site, .prop-site * { -webkit-print-color-adjust: exact !important; print-color-adjust: exact !important; }
  /* não quebrar um imóvel/seção no meio da página */
  .prop-item, .prop-atend, .prop-footer, .prop-hero2, .prop-why, .prop-comment { break-inside: avoid; page-break-inside: avoid; }
  .prop-sec-head { break-after: avoid; }
  .prop-site { background: #fff !important; }
  .prop-nav, .prop-vid-edit, .prop-instit, .prop-footer-wave, .prop-item-ctrl, .prop-hero2-meta { display: none !important; }
  .prop-hero2 { min-height: 0 !important; background: #fff !important; color: #3D2B1E !important; padding: 0 0 22px !important; border-bottom: 2px solid #3D2B1E; }
  .prop-hero2-scrim { display: none !important; }
  .prop-hero2-eyebrow { color: var(--p-accent) !important; }
  .prop-hero2-title { color: #3D2B1E !important; text-shadow: none !important; }
  .prop-hero2-lede { color: #6e5b49 !important; opacity: 1 !important; }
  .prop-hero2 .prop-chip { border-color: #ddd1b6 !important; color: #6e5b49 !important; }
  .prop-imoveis { padding: 22px 0 !important; max-width: none !important; }
  .prop-atend { background: #fff !important; color: #3D2B1E !important; padding: 26px 0 !important; border-top: 1px solid #ddd1b6; }
  .prop-atend h2, .prop-atend > p { color: #3D2B1E !important; opacity: 1 !important; }
  .prop-atend .prop-eyebrow { color: var(--p-accent) !important; }
  .prop-btn { background: #fff !important; color: var(--p-accent) !important; border-color: var(--p-accent) !important; }
  .prop-footer { background: #fff !important; color: #6e5b49 !important; padding: 22px 0 0 !important; border-top: 1px solid #ddd1b6; }
  .prop-footer-col a, .prop-footer-col span, .prop-footer-brand p { color: #6e5b49 !important; }
  .prop-footer-col h4, .prop-footer-brand .prop-mark { color: #3D2B1E !important; }
}
.prop-foot-sign { text-align: right; font-size: .78rem; line-height: 1.7; color: var(--p-soft); }
.prop-foot-sign .prop-mark { display: block; font-size: 1.2rem; margin-bottom: 6px; }
@media (max-width: 720px) {
  .prop-item, .prop-item:nth-child(even) { grid-template-columns: 1fr; }
  .prop-item:nth-child(even) .prop-item-media { order: 0; }
}

/* =========================================================================
   ANÚNCIO ZAP
   ========================================================================= */
.zap-output { display: flex; flex-direction: column; gap: 18px; }
.zap-block { border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.zap-block-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px; background: var(--surface-2); border-bottom: 1px solid var(--line);
}
.zap-block-head .t { font-weight: 600; font-size: .82rem; letter-spacing: .02em; }
.zap-block-head .count { font-size: .74rem; color: var(--ink-faint); font-variant-numeric: tabular-nums; }
.zap-block-head .count.over { color: var(--c-red); font-weight: 700; }
.zap-block-body { padding: 16px; font-size: .92rem; line-height: 1.6; white-space: pre-wrap; }
.zap-title-out { font-family: var(--font-display); font-size: 1.25rem; }
.copy-btn {
  border: 1px solid var(--line-strong); background: var(--surface); cursor: pointer;
  border-radius: 8px; padding: 6px 12px; font-size: .78rem; font-weight: 600; color: var(--ink-soft);
  display: inline-flex; align-items: center; gap: 6px; transition: all .15s;
}
.copy-btn:hover { border-color: var(--accent); color: var(--accent); }
.copy-btn svg { width: 13px; height: 13px; }

.zap-meta-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px,1fr)); gap: 10px; }
.zap-meta-grid .mc { background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; padding: 12px; }
.zap-meta-grid .mc span { font-size: .68rem; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-faint); }
.zap-meta-grid .mc b { display: block; font-size: 1rem; margin-top: 2px; }

/* highlight de palavras-chave detectadas */
mark.kw { background: rgba(160,94,51,.18); color: var(--accent-deep); padding: 0 2px; border-radius: 3px; }

/* =========================================================================
   AUTENTICAÇÃO & SEGURANÇA
   ========================================================================= */

/* ---- User chip na topbar ---- */
.user-menu-wrap { position: relative; }
.user-chip { display: flex; align-items: center; gap: 10px; background: transparent; border: 1px solid transparent; border-radius: 999px; padding: 4px 10px 4px 4px; cursor: pointer; transition: background .15s, border-color .15s; }
.user-chip:hover { background: var(--bg-soft); border-color: var(--line); }
.user-menu-wrap.open .user-chip { background: var(--bg-soft); border-color: var(--line-strong); }
.user-chip .ava {
  width: 36px; height: 36px; border-radius: 50%; flex: none; overflow: hidden;
  background: var(--accent); color: #fff; display: grid; place-items: center;
  font-family: var(--font-display); font-weight: 700; font-size: 1.05rem;
}
.user-chip .ava img, .user-menu .ava img { width: 100%; height: 100%; object-fit: cover; }
.user-chip .ava.sm { width: 30px; height: 30px; font-size: .9rem; }
.user-chip .who { display: flex; flex-direction: column; line-height: 1.15; align-items: flex-start; }
.user-chip .who b { font-size: .84rem; font-weight: 600; }
.user-chip .chev { width: 15px; height: 15px; color: var(--ink-faint); transition: transform .2s; }
.user-menu-wrap.open .chev { transform: rotate(180deg); }
/* dropdown */
.user-menu {
  position: absolute; top: calc(100% + 8px); right: 0; min-width: 230px; z-index: 200;
  background: var(--surface); border: 1px solid var(--line); border-radius: 14px;
  box-shadow: 0 22px 60px rgba(61,43,30,.18); padding: 8px; opacity: 0; transform: translateY(-6px) scale(.98);
  pointer-events: none; transition: opacity .16s, transform .16s; transform-origin: top right;
}
.user-menu-wrap.open .user-menu { opacity: 1; transform: none; pointer-events: auto; }
.user-menu-head { display: flex; align-items: center; gap: 12px; padding: 10px 10px 12px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.user-menu .ava.lg { width: 44px; height: 44px; border-radius: 50%; overflow: hidden; flex: none; background: var(--accent); color: #fff; display: grid; place-items: center; font-family: var(--font-display); font-weight: 700; font-size: 1.2rem; }
.umh-info { display: flex; flex-direction: column; min-width: 0; }
.umh-info b { font-size: .9rem; font-weight: 600; }
.umh-info small { font-size: .76rem; color: var(--ink-faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.user-menu-item { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; background: transparent; border: 0; cursor: pointer; padding: 10px 12px; border-radius: 9px; font-family: var(--font-body); font-size: .88rem; color: var(--ink); text-decoration: none; transition: background .12s; }
.user-menu-item:hover { background: var(--bg-soft); }
.user-menu-item svg { width: 17px; height: 17px; color: var(--ink-soft); flex: none; }
.user-menu-item.danger { color: var(--c-red); }
.user-menu-item.danger svg { color: var(--c-red); }
@media (max-width: 920px) { .user-chip .who { display: none; } }

/* ---- Badges de papel ---- */
.role-badge {
  display: inline-flex; align-items: center; padding: 3px 10px; border-radius: var(--r-pill);
  font-size: .68rem; font-weight: 700; letter-spacing: .03em; width: fit-content;
}
.role-badge.mini { font-size: .6rem; padding: 2px 7px; }
.role-admin    { background: rgba(139,22,16,.12);  color: var(--c-red); }
.role-diretora { background: rgba(0,69,107,.12);    color: var(--c-navy); }
.role-corretor { background: rgba(160,94,51,.14);   color: var(--accent-deep); }

/* ---- Tela de login ---- */
.login-wrap { display: grid; grid-template-columns: 1.05fr 1fr; min-height: 100vh; }
@media (max-width: 860px) { .login-wrap { grid-template-columns: 1fr; } .login-brand { display: none; } }

.login-brand {
  position: relative; overflow: hidden; color: var(--c-cream);
  padding: 48px; display: flex; flex-direction: column; justify-content: space-between;
  background:
    radial-gradient(900px 380px at 75% 0%, rgba(160,94,51,.22), transparent 60%),
    linear-gradient(150deg, var(--c-espresso), #1c110b 75%);
}
.login-brand-top { display: flex; align-items: baseline; gap: 12px; }
.login-brand-top .wordmark { font-size: 1.7rem; color: var(--c-cream); }
.login-brand-top .login-sub { font-size: .66rem; letter-spacing: .26em; text-transform: uppercase; color: rgba(237,231,207,.6); font-weight: 600; }
.login-brand-mid h1 { font-size: clamp(2rem, 3.5vw, 3rem); line-height: 1.05; }
.login-brand-mid p { color: rgba(237,231,207,.75); font-weight: 300; max-width: 42ch; margin-top: 16px; }
.login-brand .palette-strip { margin-top: 0; }

.login-form-col { display: flex; align-items: center; justify-content: center; padding: 40px 24px; background: var(--bg); }
.login-card { width: 100%; max-width: 400px; }
.login-card .eyebrow { display: block; }

.pw-wrap { position: relative; }
.pw-wrap .input { padding-right: 46px; }
.pw-toggle {
  position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
  width: 32px; height: 32px; border: none; background: transparent; cursor: pointer;
  color: var(--ink-faint); display: grid; place-items: center; border-radius: 8px;
}
.pw-toggle:hover { color: var(--accent); background: var(--bg-soft); }
.pw-toggle svg { width: 18px; height: 18px; }

.login-error {
  display: none; background: rgba(139,22,16,.08); border: 1px solid rgba(139,22,16,.25);
  color: var(--c-red); padding: 10px 14px; border-radius: var(--r-sm); font-size: .85rem; margin-bottom: 14px;
}
.login-error.show { display: block; }

.login-demo { margin-top: 26px; padding-top: 22px; border-top: 1px dashed var(--line-strong); }
.login-demo-title { font-size: .72rem; text-transform: uppercase; letter-spacing: .12em; color: var(--ink-faint); font-weight: 600; margin-bottom: 12px; }
.login-demo-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.login-demo-grid button {
  text-align: left; border: 1px solid var(--line); background: var(--surface);
  border-radius: 10px; padding: 9px 12px; cursor: pointer; transition: all .15s;
  display: flex; flex-direction: column; gap: 1px;
}
.login-demo-grid button:hover { border-color: var(--accent); background: var(--surface-2); }
.login-demo-grid button b { font-size: .8rem; }
.login-demo-grid button span { font-size: .7rem; color: var(--ink-faint); }
.login-demo-pw { font-size: .76rem; color: var(--ink-soft); margin-top: 12px; }
.login-demo-pw code { background: var(--bg-soft); padding: 2px 8px; border-radius: 6px; border: 1px solid var(--line); }

/* ---- Tabela de dados (usuários / logs) ---- */
.data-table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.data-table th {
  text-align: left; padding: 14px 18px; background: var(--surface-2);
  font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-faint); font-weight: 700;
  border-bottom: 1px solid var(--line);
}
.data-table td { padding: 13px 18px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.data-table tr:last-child td { border-bottom: none; }
.data-table tr:hover td { background: var(--surface-2); }
.data-table .nowrap { white-space: nowrap; }
.cell-user { display: flex; align-items: center; gap: 11px; }
.cell-user .sub { display: block; font-size: .74rem; color: var(--ink-faint); }
.row-actions { display: flex; gap: 6px; justify-content: flex-end; }
.icon-action {
  border: 1px solid var(--line); background: var(--surface); width: 32px; height: 32px;
  border-radius: 8px; cursor: pointer; font-size: .9rem; color: var(--ink-soft); transition: all .15s;
}
.icon-action:hover { border-color: var(--accent); color: var(--accent); }
.icon-action.danger:hover { border-color: var(--c-red); color: var(--c-red); }

.status { font-size: .78rem; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; }
.status::before { content: ''; width: 7px; height: 7px; border-radius: 50%; }
.status.on { color: var(--c-green); } .status.on::before { background: #2e9e5b; }
.status.off { color: var(--ink-faint); } .status.off::before { background: var(--ink-faint); }

/* ---- Modal ---- */
.modal-backdrop {
  position: fixed; inset: 0; background: rgba(36,25,19,.45); backdrop-filter: blur(3px);
  display: none; align-items: center; justify-content: center; z-index: 200; padding: 20px;
}
.modal-backdrop.show { display: flex; }
.modal {
  background: var(--surface); border-radius: var(--r-lg); padding: 30px;
  width: 100%; max-width: 480px; box-shadow: var(--shadow-lg); max-height: 90vh; overflow-y: auto;
}

/* ---- Cards de resumo (stats) ---- */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 16px; }
.stat-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r);
  padding: 18px 20px; box-shadow: var(--shadow-sm); position: relative;
}
.stat-card.danger { border-color: rgba(139,22,16,.3); }
.stat-card .stat-ic { position: absolute; top: 16px; right: 16px; color: var(--accent); opacity: .5; }
.stat-card .stat-ic svg { width: 20px; height: 20px; }
.stat-card.danger .stat-ic { color: var(--c-red); }
.stat-card b { font-family: var(--font-display); font-size: 2rem; display: block; line-height: 1; }
.stat-card span { font-size: .8rem; color: var(--ink-soft); }

/* ---- Linha de registro gerado ---- */
.rec-row { display: flex; align-items: center; gap: 14px; padding: 12px 4px; border-bottom: 1px solid var(--line); }
.rec-row:last-child { border-bottom: none; }
.rec-ic { width: 38px; height: 38px; border-radius: 10px; background: var(--bg-soft); border: 1px solid var(--line); display: grid; place-items: center; color: var(--accent); flex: none; }
.rec-ic svg { width: 18px; height: 18px; }
.rec-meta { flex: 1; min-width: 0; }
.rec-meta b { font-size: .92rem; font-weight: 600; display: block; }
.rec-meta .sub { font-size: .78rem; color: var(--ink-faint); }
.rec-owner { font-size: .76rem; font-weight: 600; color: var(--c-navy); background: rgba(0,69,107,.1); padding: 3px 10px; border-radius: var(--r-pill); white-space: nowrap; }
.rec-when { font-size: .76rem; color: var(--ink-faint); white-space: nowrap; }
a.rec-link { text-decoration: none; color: inherit; border-radius: 10px; transition: background .12s; }
a.rec-link:hover { background: var(--bg-soft); }
.rec-go { flex: none; color: var(--ink-faint); display: grid; place-items: center; opacity: 0; transition: opacity .12s, transform .12s; }
.rec-go svg { width: 16px; height: 16px; }
a.rec-link:hover .rec-go { opacity: 1; transform: translateX(2px); color: var(--accent); }

/* ---- Pontinho de log ---- */
.log-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 8px; background: var(--ink-faint); }
.log-dot.tone-ok { background: #2e9e5b; }
.log-dot.tone-danger { background: var(--c-red); }
.log-dot.tone-info { background: var(--c-navy); }
.log-dot.tone-muted { background: var(--ink-faint); }

/* ---- Sessão & danger zone ---- */
.session-info { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px,1fr)); gap: 14px; margin-bottom: 22px; }
.session-info > div { background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r); padding: 14px; }
.session-info span { font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-faint); display: block; }
.session-info b { font-size: .9rem; }
.danger-zone {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 16px 0; border-top: 1px solid var(--line);
}
.danger-zone b { font-size: .9rem; }
.danger-zone p { font-size: .8rem; margin: 2px 0 0; }

/* =========================================================================
   GERENCIADOR DE FOTOS (upload + miniaturas)
   ========================================================================= */
.photos { border-radius: var(--r); transition: outline-color .15s; }
.photos.drag { outline: 2px dashed var(--accent); outline-offset: 4px; }
.photos.uploading { opacity: .7; pointer-events: none; }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.photo-thumb { position: relative; aspect-ratio: 4 / 3; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); background: var(--bg-soft); }
.photo-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo-thumb.broken { display: grid; place-items: center; }
.photo-thumb.broken img { display: none; }
.photo-thumb.broken::after { content: '✕ imagem'; font-size: .7rem; color: var(--ink-faint); }
.photo-x {
  position: absolute; top: 5px; right: 5px; width: 22px; height: 22px; border-radius: 50%;
  border: none; background: rgba(36,25,19,.72); color: #fff; cursor: pointer;
  font-size: .72rem; line-height: 1; display: grid; place-items: center; opacity: 0; transition: opacity .15s, background .15s;
}
.photo-thumb:hover .photo-x { opacity: 1; }
.photo-x:hover { background: var(--c-red); }
.photo-add {
  aspect-ratio: 4 / 3; border: 1.5px dashed var(--line-strong); border-radius: 10px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  cursor: pointer; color: var(--ink-soft); font-size: .76rem; text-align: center; padding: 4px;
  transition: border-color .15s, color .15s, background .15s;
}
.photo-add:hover { border-color: var(--accent); color: var(--accent); background: var(--surface-2); }
.photo-add svg { width: 20px; height: 20px; }
.photo-urlrow { margin-top: 8px; }
.photo-urlrow .input { font-size: .82rem; }

/* galeria do imóvel no documento de proposta */
.prop-gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: 5px; margin-bottom: 12px; }
.prop-gallery img { width: 100%; height: 74px; object-fit: cover; border-radius: 6px; display: block; }

/* =========================================================================
   CHECKLIST (diferenciais / itens indispensáveis)
   ========================================================================= */
.chk-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 7px 9px; }
.chk {
  display: flex; align-items: center; gap: 8px; padding: 8px 11px;
  border: 1px solid var(--line); border-radius: 10px; cursor: pointer;
  font-size: .84rem; background: var(--surface); transition: border-color .15s, background .15s;
}
.chk:hover { border-color: var(--line-strong); }
.chk.on { border-color: var(--accent); background: var(--bg-soft); }
.chk input { accent-color: var(--accent); width: 15px; height: 15px; flex: none; cursor: pointer; }
.chk span { flex: 1; line-height: 1.2; }
.chk-x { cursor: pointer; opacity: .5; font-style: normal; font-size: .72rem; font-weight: 700; }
.chk-x:hover { opacity: 1; color: var(--c-red); }
.chk-add { display: flex; gap: 8px; margin-top: 12px; }
.chk-add .input { flex: 1; }
.chk-group-title {
  font-size: .7rem; text-transform: uppercase; letter-spacing: .1em; color: var(--ink-faint);
  font-weight: 700; margin: 16px 0 9px; padding-bottom: 5px; border-bottom: 1px solid var(--line);
}
.chk-group-title:first-child { margin-top: 0; }

/* ---- Editor de layout em tela cheia (landing) ---- */
.lp-stage { position: fixed; inset: 0; z-index: 300; display: flex; flex-direction: column; background: #0c0a08; }
.lp-stage-bar { position: relative; z-index: 20; flex: none; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 10px 18px; background: var(--c-espresso); color: var(--c-cream); }
/* Dentro do palco, a nav da landing NÃO pode ser fixa (cobriria a barra de controle no topo e bloquearia os cliques) */
.lp-stage .lp-nav { position: absolute !important; }
.lp-stage-bar .t { font-size: .84rem; opacity: .85; }
.lp-stage-body { flex: 1; overflow-y: auto; background: #f6f2e9; }
body.lp-stage-open { overflow: hidden; }
@media (max-width: 640px) { .lp-stage-bar .t { display: none; } }

/* ---- Cropper de imagem (editor de layout) ---- */
.lp-cropper { position: fixed; inset: 0; z-index: 400; background: rgba(15,9,6,.7); backdrop-filter: blur(3px); display: flex; align-items: center; justify-content: center; padding: 20px; }
.lp-cropper-card { background: var(--surface); border-radius: 16px; padding: 22px; width: 100%; max-width: 460px; box-shadow: var(--shadow-lg); }
.lp-cropper-card h3 { font-family: var(--font-display); font-size: 1.4rem; margin: 0 0 14px; }
.lp-cropper-view { aspect-ratio: 4/3; overflow: hidden; border-radius: 10px; background: #000; cursor: grab; touch-action: none; }
.lp-cropper-view:active { cursor: grabbing; }
.lp-cropper-view img { width: 100%; height: 100%; display: block; user-select: none; pointer-events: none; }
.lp-cropper-zoom { display: flex; align-items: center; gap: 10px; font-size: .8rem; color: var(--ink-soft); margin-top: 14px; }
.lp-cropper-zoom input { flex: 1; accent-color: var(--accent); }
.lp-cropper-hint { font-size: .76rem; color: var(--ink-faint); margin: 6px 0 14px; }
.lp-cropper-actions { display: flex; align-items: center; gap: 8px; }

/* ---- Impressão ---- */
@media print {
  .topbar, .actions-bar, .no-print { display: none !important; }
  body { background: #fff; }
  .wrap-page { padding: 0; max-width: none; }
  .prop, .lp { box-shadow: none; }
  /* impressão da proposta a partir do palco em tela cheia: mostra só o documento */
  body.print-prop > * { display: none !important; }
  body.print-prop #propStage { display: flex !important; position: static !important; height: auto !important; background: #fff !important; overflow: visible !important; }
  body.print-prop #propStage .lp-stage-bar { display: none !important; }
  body.print-prop #propStage .lp-stage-body { overflow: visible !important; background: #fff !important; }
}
