/* Fontes da marca (Poppins e Inter, licença SIL OFL), servidas pelo próprio app */
@font-face { font-family: "Poppins"; font-style: normal; font-weight: 500; font-display: swap; src: url("/fonts/poppins-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Poppins"; font-style: normal; font-weight: 600; font-display: swap; src: url("/fonts/poppins-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Poppins"; font-style: normal; font-weight: 700; font-display: swap; src: url("/fonts/poppins-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "Poppins"; font-style: normal; font-weight: 800; font-display: swap; src: url("/fonts/poppins-latin-800-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 400; font-display: swap; src: url("/fonts/inter-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 500; font-display: swap; src: url("/fonts/inter-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 600; font-display: swap; src: url("/fonts/inter-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 700; font-display: swap; src: url("/fonts/inter-latin-700-normal.woff2") format("woff2"); }

:root {
  /* MY MATCHER — kit de identidade 1.0: marinho #0B2D5B · azul destaque #3B82F6 · cinza suporte #E5EAF2 · off-white #F8FAFC · texto #334155 */
  color-scheme: light;
  --navy: #0B2D5B;
  --navy-2: #0F3A72;
  --blue: #3B82F6;
  --blue-2: #2563EB;
  --bg: #F8FAFC;
  --bg-2: #F1F5F9;
  --surface: #FFFFFF;
  --surface-2: #F8FAFC;
  --surface-3: #E5EAF2;
  --line: #E5EAF2;
  --line-2: #CBD5E1;
  /* nomes antigos mantidos: "gold" agora é o azul de destaque, "gold-2" o marinho dos títulos */
  --gold: #3B82F6;
  --gold-2: #0B2D5B;
  --gold-dim: #5B7395;
  --gold-wash: rgba(59, 130, 246, 0.08);
  --text: #334155;
  --muted: #64748B;
  --faint: #94A3B8;
  --compra: #3B82F6;
  --venda: #0B2D5B;
  --locacao: #F59E0B;
  --ok: #16A34A;
  --warn: #D97706;
  --danger: #DC2626;
  --serif: "Poppins", "Inter", system-ui, sans-serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --r: 14px;
  --r-sm: 10px;
  --shadow: 0 18px 50px -24px rgba(11, 45, 91, 0.28);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
}

* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--text); }
body {
  font: 15px/1.5 var(--sans);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  min-height: 100dvh;
}
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--gold); }
::selection { background: rgba(59, 130, 246, 0.22); }

.serif { font-family: var(--serif); }
.caps { text-transform: uppercase; letter-spacing: 0.16em; }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.hidden { display: none !important; }

/* ---------- layout ---------- */
.app { display: grid; grid-template-columns: 248px 1fr; min-height: 100dvh; }
.side {
  position: sticky; top: 0; height: 100dvh;
  background: var(--navy); color: #fff;
  padding: 26px 16px; display: flex; flex-direction: column; gap: 26px;
}
.side-logo { padding: 2px 8px 4px; }
.side-logo .mm-logo { --mm-h: 40px; }
.nav { display: flex; flex-direction: column; gap: 4px; }
.nav a {
  display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 10px;
  color: rgba(255, 255, 255, .72); text-decoration: none; font-weight: 500; letter-spacing: 0.01em;
}
.nav a svg { width: 18px; height: 18px; flex: none; }
.nav a:hover { color: #fff; background: rgba(255, 255, 255, .07); }
.nav a.on { color: #fff; background: rgba(59, 130, 246, .28); box-shadow: inset 3px 0 0 var(--blue); }
.side .who { margin-top: auto; font-size: 13px; color: rgba(255, 255, 255, .8); display: flex; align-items: center; gap: 10px; padding: 0 6px; }
.side .who .av { background: rgba(255, 255, 255, .12); color: #fff; border-color: rgba(255, 255, 255, .2); }
.side .who .icon-btn { color: rgba(255, 255, 255, .7); }
.side .who .icon-btn:hover { color: #fff; background: rgba(255, 255, 255, .08); }

.main { min-width: 0; padding: 32px 40px 80px; max-width: 1360px; width: 100%; }
.topbar { display: none; }
.tabbar { display: none; }

.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 26px; flex-wrap: wrap; }
.page-head h1 { font-family: var(--serif); font-weight: 700; font-size: 28px; letter-spacing: -0.01em; margin: 0; color: var(--navy); }
.page-head .sub { color: var(--muted); margin-top: 4px; font-size: 14px; }
.eyebrow { font-size: 11px; text-transform: uppercase; letter-spacing: 0.16em; color: var(--blue); font-weight: 600; margin-bottom: 6px; }

/* ---------- controls ---------- */
.btn {
  appearance: none; border: 1px solid var(--line-2); background: var(--surface); color: var(--navy);
  padding: 9px 16px; border-radius: 999px; cursor: pointer; font-weight: 500; font-size: 14px;
  display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; transition: background .15s, border-color .15s; text-decoration: none;
}
.btn:hover { border-color: var(--blue); }
.btn svg { width: 16px; height: 16px; }
.btn.gold { background: var(--blue); color: #FFFFFF; border-color: var(--blue); font-weight: 600; }
.btn.gold:hover { background: var(--blue-2); border-color: var(--blue-2); }
.btn.ghost { background: transparent; }
.btn.danger { color: var(--danger); border-color: rgba(220, 38, 38, 0.3); background: transparent; }
.btn.sm { padding: 6px 12px; font-size: 13px; }
.btn:disabled { opacity: .5; cursor: default; }
.icon-btn { appearance: none; background: transparent; border: 0; color: var(--muted); cursor: pointer; padding: 8px; border-radius: 10px; display: inline-grid; place-items: center; }
.icon-btn:hover { color: var(--text); background: var(--gold-wash); }
.icon-btn svg { width: 20px; height: 20px; }

.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > span { font-size: 12px; color: var(--muted); letter-spacing: 0.04em; }
.input, select.input, textarea.input {
  width: 100%; background: var(--surface); color: var(--text); border: 1px solid var(--line); border-radius: var(--r-sm);
  padding: 10px 12px; outline: none; transition: border-color .15s, box-shadow .15s;
}
.input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15); }
textarea.input { resize: vertical; min-height: 84px; }
select.input { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 17px) 55%, calc(100% - 12px) 55%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 32px; }
.grid { display: grid; gap: 14px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.seg { display: inline-flex; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 3px; gap: 2px; }
.seg button { appearance: none; border: 0; background: transparent; color: var(--muted); padding: 7px 14px; border-radius: 999px; cursor: pointer; font-size: 13px; font-weight: 500; white-space: nowrap; }
.seg button.on { background: var(--navy); color: #fff; }

.toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 18px; }
.search { position: relative; flex: 1 1 240px; max-width: 360px; }
.search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; color: var(--faint); }
.search .input { padding-left: 36px; border-radius: 999px; }

/* ---------- cards & panels ---------- */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 20px; box-shadow: 0 1px 2px rgba(11, 45, 91, .04); }
.panel h2 { font-family: var(--serif); font-weight: 600; font-size: 17px; letter-spacing: 0; margin: 0 0 14px; color: var(--gold-2); display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.panel h2 small { font-family: var(--sans); font-size: 12px; color: var(--muted); letter-spacing: 0; }

.kpis { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px; margin-bottom: 18px; }
.kpi { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px 18px; cursor: pointer; transition: border-color .15s; }
.kpi:hover { border-color: var(--line-2); }
.kpi .lbl { font-size: 12px; color: var(--muted); display: flex; align-items: center; gap: 8px; }
.kpi .num { font-family: var(--serif); font-weight: 700; font-size: 32px; color: var(--navy); line-height: 1.15; margin-top: 6px; font-variant-numeric: tabular-nums; }
.kpi.alert .num { color: var(--warn); }
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; flex: none; }
.dot.compra { background: var(--compra); } .dot.venda { background: var(--venda); } .dot.locacao { background: var(--locacao); }

.dash { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 18px; }
.dash .col { display: flex; flex-direction: column; gap: 18px; min-width: 0; }

.funil { display: flex; flex-direction: column; gap: 10px; }
.funil-row { display: grid; grid-template-columns: 120px 1fr 34px; align-items: center; gap: 12px; font-size: 13px; cursor: pointer; }
.funil-row .bar { height: 10px; border-radius: 99px; background: var(--bg-2); overflow: hidden; display: flex; }
.funil-row .bar i { display: block; height: 100%; }
.funil-row .n { text-align: right; font-variant-numeric: tabular-nums; color: var(--text); }
.legend { display: flex; gap: 16px; font-size: 12px; color: var(--muted); margin-top: 14px; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }

.list { display: flex; flex-direction: column; }
.row { display: flex; gap: 12px; align-items: center; padding: 12px 4px; border-top: 1px solid var(--line); cursor: pointer; }
.row:first-child { border-top: 0; }
.row:hover .row-title { color: var(--blue); }
.row-main { min-width: 0; flex: 1; }
.row-title { font-weight: 500; color: var(--navy); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.row-sub { font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.time { font-family: var(--serif); color: var(--blue); font-weight: 600; font-size: 15px; width: 52px; flex: none; font-variant-numeric: tabular-nums; }
.empty { padding: 28px 8px; text-align: center; color: var(--muted); font-size: 14px; }
.empty .serif { color: var(--navy); font-weight: 600; font-size: 17px; display: block; margin-bottom: 4px; }

/* demand card */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px 16px 14px;
  cursor: pointer; display: flex; flex-direction: column; gap: 10px; position: relative; transition: border-color .15s, transform .15s;
}
.card:hover { border-color: var(--line-2); }
.card::before { content: ""; position: absolute; left: 0; top: 14px; bottom: 14px; width: 2px; border-radius: 2px; background: var(--tipo, var(--gold)); opacity: .8; }
.card[data-tipo="compra"] { --tipo: var(--compra); }
.card[data-tipo="venda"] { --tipo: var(--venda); }
.card[data-tipo="locacao"] { --tipo: var(--locacao); }
.card-top { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); }
.card-id { font-family: var(--serif); color: var(--blue); font-weight: 600; font-size: 14px; }
.card-title { font-weight: 600; line-height: 1.35; color: var(--navy); }
.card-meta { display: flex; flex-wrap: wrap; gap: 6px; }
.card-foot { display: flex; align-items: center; justify-content: space-between; font-size: 12px; color: var(--muted); gap: 8px; }
.tag { display: inline-flex; align-items: center; gap: 6px; padding: 3px 9px; border-radius: 999px; font-size: 12px; border: 1px solid var(--line); color: var(--muted); background: var(--bg-2); white-space: nowrap; }
.tag.tipo { color: var(--tipo); border-color: color-mix(in srgb, var(--tipo) 35%, transparent); }
.tag.hot { color: var(--warn); border-color: rgba(217, 119, 6, .3); }
.tag.st-nova { color: var(--gold-2); }
.tag.st-fechada { color: var(--ok); border-color: rgba(22, 163, 74, .3); }
.tag.st-perdida { color: var(--faint); }
.av { width: 24px; height: 24px; border-radius: 50%; display: inline-grid; place-items: center; font-size: 11px; font-weight: 600; background: var(--surface-3); color: var(--gold); border: 1px solid var(--line-2); flex: none; }
.av.Melissa { color: var(--navy); }
.av.Ambos { font-size: 10px; }
.stale { color: var(--warn); }

/* kanban */
.board { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(270px, 1fr); gap: 14px; overflow-x: auto; padding-bottom: 12px; scroll-snap-type: x mandatory; }
.col-k { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--r); padding: 12px; min-height: 240px; scroll-snap-align: start; display: flex; flex-direction: column; gap: 10px; }
.col-k.over { border-color: var(--gold-dim); background: var(--gold-wash); }
.col-k h3 { margin: 2px 4px 4px; font-family: var(--serif); font-weight: 600; font-size: 13px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--navy); display: flex; justify-content: space-between; }
.col-k h3 span { color: var(--muted); font-family: var(--sans); }
.col-k .card { padding: 13px 13px 12px; }

/* ---------- drawer / sheet ---------- */
.scrim { position: fixed; inset: 0; background: rgba(11, 45, 91, .32); backdrop-filter: blur(2px); z-index: 40; animation: fade .18s ease; }
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; width: min(640px, 100vw); background: var(--surface); border-left: 1px solid var(--line-2);
  z-index: 50; display: flex; flex-direction: column; box-shadow: var(--shadow); animation: slide .22s cubic-bezier(.2, .8, .2, 1);
}
.drawer-head { padding: 18px 22px 14px; border-bottom: 1px solid var(--line); display: flex; gap: 12px; align-items: flex-start; padding-top: calc(18px + var(--safe-t)); }
.drawer-head h2 { margin: 0; font-family: var(--serif); font-weight: 600; font-size: 21px; line-height: 1.3; color: var(--navy); }
.drawer-body { padding: 18px 22px 30px; overflow-y: auto; flex: 1; display: flex; flex-direction: column; gap: 22px; }
.drawer-foot { padding: 14px 22px calc(14px + var(--safe-b)); border-top: 1px solid var(--line); display: flex; gap: 10px; justify-content: flex-end; background: var(--surface); flex-wrap: wrap; }
.sec h3 { font-size: 11px; text-transform: uppercase; letter-spacing: 0.14em; color: var(--blue); margin: 0 0 12px; font-weight: 600; }
@keyframes slide { from { transform: translateX(40px); opacity: 0; } }
@keyframes fade { from { opacity: 0; } }

.stepper { display: flex; gap: 6px; flex-wrap: wrap; }
.stepper button { appearance: none; border: 1px solid var(--line); background: var(--bg-2); color: var(--muted); border-radius: 999px; padding: 7px 12px; font-size: 13px; cursor: pointer; }
.stepper button.on { background: var(--blue); color: #FFFFFF; border-color: var(--blue); font-weight: 600; }
.stepper button.done { color: var(--navy); border-color: var(--line-2); background: var(--surface-3); }

.timeline { display: flex; flex-direction: column; gap: 0; }
.tl { display: grid; grid-template-columns: 14px 1fr; gap: 12px; padding-bottom: 14px; position: relative; }
.tl::before { content: ""; position: absolute; left: 6px; top: 16px; bottom: 0; width: 1px; background: var(--line); }
.tl:last-child::before { display: none; }
.tl i { width: 9px; height: 9px; border-radius: 50%; border: 1px solid var(--gold); margin: 6px 0 0 2px; background: var(--surface); }
.tl .meta { font-size: 12px; color: var(--muted); }
.copybox { white-space: pre-wrap; background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 14px; font-size: 14px; max-height: 260px; overflow: auto; }
.msg-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 10px; }
.msg-btn { appearance: none; text-align: left; cursor: pointer; background: var(--bg-2); border: 1px solid var(--line-2); border-radius: var(--r-sm); padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; color: var(--text); transition: border-color .15s, background .15s; }
.msg-btn b { display: flex; align-items: center; gap: 8px; font-weight: 600; color: var(--gold-2); }
.msg-btn b svg { width: 17px; height: 17px; }
.msg-btn span { font-size: 12.5px; color: var(--muted); }
.msg-btn:hover { border-color: var(--gold-dim); }
.msg-btn.on { background: var(--gold-wash); border-color: var(--gold); }
@media (max-width: 760px) { .msg-btns { grid-template-columns: 1fr; } .toast { bottom: calc(92px + var(--safe-b)); } }
.note-in { display: flex; gap: 8px; margin-bottom: 14px; }

/* ---------- agenda ---------- */
.day { margin-bottom: 22px; }
.day h3 { font-family: var(--serif); font-weight: 600; color: var(--navy); font-size: 16px; letter-spacing: 0.04em; margin: 0 0 8px; text-transform: capitalize; display: flex; gap: 10px; align-items: baseline; }
.day h3 small { font-family: var(--sans); font-size: 12px; color: var(--muted); text-transform: none; }
.ev { display: flex; gap: 14px; align-items: center; padding: 12px 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-sm); margin-bottom: 8px; }
.ev .row-main { cursor: default; }
.ev.linked .row-main { cursor: pointer; }
.src { font-size: 11px; color: var(--faint); }

/* ---------- settings ---------- */
.status-pills { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 20px; }
.pill { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 13px; }
.pill .dot { background: var(--faint); }
.pill.ok .dot { background: var(--ok); box-shadow: 0 0 0 4px rgba(22, 163, 74, .12); }
.settings { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; align-items: start; }
.settings .panel p { color: var(--muted); font-size: 14px; margin: 0 0 14px; }
.codeline { display: flex; gap: 8px; align-items: center; background: var(--bg-2); border: 1px dashed var(--line-2); border-radius: var(--r-sm); padding: 8px 8px 8px 12px; font-family: ui-monospace, Menlo, monospace; font-size: 12.5px; color: var(--navy); }
.codeline code { flex: 1; overflow-x: auto; white-space: nowrap; }
ol.steps { margin: 0 0 14px; padding-left: 20px; color: var(--muted); font-size: 14px; }
ol.steps li { margin-bottom: 6px; }
ol.steps b { color: var(--text); font-weight: 500; }

.chat { display: flex; flex-direction: column; gap: 8px; max-height: 380px; overflow-y: auto; padding: 4px 2px 12px; }
.bubble { max-width: 88%; padding: 9px 13px; border-radius: 14px; font-size: 14px; white-space: pre-wrap; word-wrap: break-word; }
.bubble.me { align-self: flex-end; background: #DBEAFE; color: var(--navy); border-bottom-right-radius: 4px; }
.bubble.bot { align-self: flex-start; background: var(--surface-2); border: 1px solid var(--line); border-bottom-left-radius: 4px; }

/* ---------- login ---------- */
.login { min-height: 100dvh; display: grid; place-items: center; padding: 24px; background: radial-gradient(ellipse at 50% 0%, rgba(59, 130, 246, .10), transparent 60%), var(--bg); }
.login-box { width: min(380px, 100%); text-align: center; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 36px 28px 30px; box-shadow: var(--shadow); }
.login-logo { display: flex; justify-content: center; margin-bottom: 10px; }
.login-logo .mm-logo { --mm-h: 58px; }
.login-box .tag-line { color: var(--navy); font-family: var(--serif); font-weight: 600; font-size: 17px; margin: 14px 0 28px; }
.login-box .tag-line em { font-style: normal; color: var(--blue); }
.login-box form { display: flex; flex-direction: column; gap: 14px; text-align: left; }
.login-box .seg { width: 100%; }
.login-box .seg button { flex: 1; padding: 10px; }
.err { color: var(--danger); font-size: 13px; min-height: 18px; }

/* ---------- toast ---------- */
.toast { position: fixed; left: 50%; bottom: calc(28px + var(--safe-b)); transform: translateX(-50%); background: var(--surface-3); border: 1px solid var(--line-2); color: var(--text); padding: 11px 18px; border-radius: 999px; z-index: 80; font-size: 14px; box-shadow: var(--shadow); animation: fade .2s; max-width: calc(100vw - 32px); }

.fab { display: none; }

/* ---------- mobile ---------- */
@media (max-width: 980px) {
  .kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .dash, .settings { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  body { font-size: 15px; }
  .app { display: block; }
  .side { display: none; }
  .topbar {
    display: flex; align-items: center; justify-content: space-between; position: sticky; top: 0; z-index: 30;
    padding: calc(10px + var(--safe-t)) 16px 10px; background: rgba(255, 255, 255, .94); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line);
  }
  
  .main { padding: 18px 16px calc(96px + var(--safe-b)); }
  .page-head { margin-bottom: 18px; }
  .page-head h1 { font-size: 24px; }
  .page-head .actions { display: none; }
  .kpis { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
  .kpis .kpi:first-child { grid-column: span 4; display: flex; align-items: center; justify-content: space-between; }
  .kpis .kpi:first-child .num { margin: 0; font-size: 34px; }
  .kpi { padding: 12px 10px; }
  .kpi .lbl { font-size: 11px; gap: 5px; white-space: nowrap; overflow: hidden; }
  .kpi .num { font-size: 24px; margin-top: 2px; }
  .kpi[data-kpi="paradas"] .lbl { font-size: 0; }
  .kpi[data-kpi="paradas"] .lbl::after { content: "Paradas"; font-size: 11px; }
  .panel { padding: 16px; }
  .panel h2 { flex-wrap: wrap; row-gap: 2px; }
  .funil-row span:first-child { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .g2, .g3, .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g2.stack { grid-template-columns: 1fr; }
  .cards { grid-template-columns: 1fr; }
  .board { grid-auto-columns: 84vw; margin: 0 -16px; padding: 0 16px 12px; }
  .toolbar .search { max-width: none; flex-basis: 100%; }
  .toolbar { gap: 8px; }
  .toolbar .seg { overflow-x: auto; max-width: 100%; }
  .drawer { width: 100vw; border-left: 0; animation: up .25s cubic-bezier(.2, .8, .2, 1); }
  @keyframes up { from { transform: translateY(30px); opacity: 0; } }
  .drawer-head, .drawer-body, .drawer-foot { padding-left: 16px; padding-right: 16px; }
  .funil-row { grid-template-columns: 96px 1fr 28px; }
  .tabbar {
    display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
    background: rgba(255, 255, 255, .97); backdrop-filter: blur(12px); border-top: 1px solid var(--line); padding: 6px 4px calc(6px + var(--safe-b));
  }
  .tabbar a { display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 10.5px; color: var(--muted); text-decoration: none; padding: 6px 0; letter-spacing: .02em; }
  .tabbar a svg { width: 22px; height: 22px; }
  .tabbar a.on { color: var(--gold); }
  .tabbar .plus span { width: 46px; height: 46px; margin-top: -18px; border-radius: 50%; background: var(--gold); color: #FFFFFF; display: grid; place-items: center; box-shadow: 0 8px 24px -8px rgba(59, 130, 246, .5); }
  .tabbar .plus svg { width: 24px; height: 24px; }
}

.page-head .actions.always { display: flex; }
@media (max-width: 760px) { .page-head .actions.always { display: flex; width: 100%; } .page-head .actions.always .btn { flex: 1 1 auto; justify-content: center; } }

/* ---------- To Do List ---------- */
.tnova { display: grid; grid-template-columns: 1fr 160px 120px auto; gap: 10px; padding: 12px; margin-bottom: 16px; }
.tboard { grid-auto-columns: minmax(280px, 1fr); }
.tcard::before { background: var(--gold); }
.tcard.feito { opacity: .62; }
.tcard.feito .card-title { text-decoration: line-through; text-decoration-color: var(--faint); }
.tcard-top { display: flex; gap: 6px; align-items: center; font-size: 12px; }
.tcard .card-foot .btn { padding: 5px 12px; }
.fab { display: none; }
@media (max-width: 760px) {
  .tnova { grid-template-columns: 1fr 1fr; }
  .tnova #tnova { grid-column: span 2; }
  .tnova .btn { grid-column: span 2; justify-content: center; }
  .tabbar { grid-template-columns: repeat(5, 1fr); }
  .fab {
    display: grid; place-items: center; position: fixed; right: 18px; bottom: calc(84px + var(--safe-b)); z-index: 31;
    width: 54px; height: 54px; border-radius: 50%; border: 0; background: var(--gold); color: #FFFFFF;
    box-shadow: 0 10px 26px -8px rgba(59, 130, 246, .55); cursor: pointer;
  }
  .fab svg { width: 24px; height: 24px; }
  .page-head .seg { width: 100%; }
}

/* ---------- marca MY MATCHER ---------- */
.mm-logo { --mm-h: 40px; display: inline-flex; align-items: center; gap: calc(var(--mm-h) * .28); line-height: 1; }
.mm-logo svg { height: var(--mm-h); width: auto; flex: none; }
.mm-word { display: flex; flex-direction: column; font-family: var(--serif); }
.mm-word b { font-weight: 700; font-size: calc(var(--mm-h) * .3); letter-spacing: .06em; }
.mm-word strong { font-weight: 800; font-size: calc(var(--mm-h) * .5); letter-spacing: .01em; margin-top: 1px; }
.mm-word small { font-family: var(--sans); font-weight: 400; font-size: calc(var(--mm-h) * .2); letter-spacing: .18em; margin-top: 4px; white-space: nowrap; }
.mm-logo.marinho { color: var(--navy); }
.mm-logo.branco { color: #fff; }
.top-logo .mm-logo { --mm-h: 30px; }
.toast { background: var(--navy); color: #fff; border-color: var(--navy); }

/* ---------- conta de corretor (uma pessoa): sem "responsável" ---------- */
body.solo label.field:has(select[name="responsavel"]),
body.solo select[name="responsavel"],
body.solo .seg:has([data-r]),
body.solo .seg:has([data-tr]) { display: none !important; }

/* ---------- primeiros passos ---------- */
.onboard { margin-bottom: 18px; border: 1px solid rgba(59, 130, 246, .25); background: linear-gradient(180deg, #fff, var(--gold-wash)); }
.onboard-list { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 10px; }
.onboard-list li { display: grid; grid-template-columns: 32px 1fr auto; gap: 12px; align-items: center; padding: 12px 14px; border-radius: var(--r-sm); background: var(--surface); border: 1px solid var(--line); }
.onboard-list li p { margin: 2px 0 0; font-size: 13px; color: var(--muted); }
.onboard-list li.ok { opacity: .62; }
.ob-n { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; font: 700 14px var(--serif); background: var(--navy); color: #fff; }
.onboard-list li.ok .ob-n { background: var(--ok); }
@media (max-width: 760px) { .onboard-list li { grid-template-columns: 32px 1fr; } .onboard-list li > .btn, .onboard-list li > a.btn { grid-column: 2; justify-self: start; } }
