:root {
  --carvao-950: #140e0b; --carvao-900: #1d1511; --carvao-800: #2a1f19; --carvao-700: #3b2b22;
  --cobre: #c47a3c; --cobre-claro: #e3a56b; --creme: #f7f2eb; --linha: #eadfd2; --tinta: #231a15; --mudo: #7b6a5d;
  --verde: #2f6b55; --vermelho: #b4442a; --ambar: #d18b2f;
}
html, body { height: 100%; }
body { background: var(--creme); color: var(--tinta); font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif; -webkit-font-smoothing: antialiased; }
.serif { font-family: "Fraunces", Georgia, "Times New Roman", serif; letter-spacing: -0.01em; }
.num { font-variant-numeric: tabular-nums; }

/* sidebar */
.lateral { background:
  radial-gradient(120% 60% at 0% 0%, rgba(196,122,60,.18), transparent 60%),
  linear-gradient(180deg, var(--carvao-900), var(--carvao-950)); }
.nav-item { display: flex; align-items: center; gap: .75rem; padding: .62rem .9rem; border-radius: .8rem; color: rgba(255,255,255,.66);
  font-size: .9rem; font-weight: 500; transition: background .2s, color .2s; cursor: pointer; position: relative; }
.nav-item:hover { background: rgba(255,255,255,.06); color: #fff; }
.nav-item.ativo { background: linear-gradient(90deg, rgba(196,122,60,.28), rgba(196,122,60,.06)); color: #fff; }
.nav-item.ativo::before { content: ""; position: absolute; left: -12px; top: 22%; bottom: 22%; width: 3px; border-radius: 3px; background: var(--cobre-claro);
  box-shadow: 0 0 12px var(--cobre); }
.nav-item svg { width: 18px; height: 18px; flex: none; opacity: .9; }
.distintivo { margin-left: auto; font-size: .7rem; font-weight: 600; padding: .05rem .45rem; border-radius: 999px; background: var(--cobre); color: #fff; }
.ponto-vivo { width: 7px; height: 7px; border-radius: 50%; background: #4ade80; box-shadow: 0 0 0 0 rgba(74,222,128,.6); animation: pulsar 2.4s infinite; flex: none; }
@keyframes pulsar { 0% { box-shadow: 0 0 0 0 rgba(74,222,128,.55); } 70% { box-shadow: 0 0 0 7px rgba(74,222,128,0); } 100% { box-shadow: 0 0 0 0 rgba(74,222,128,0); } }

/* cards */
.cartao { background: #fff; border: 1px solid var(--linha); border-radius: 1.1rem; box-shadow: 0 1px 2px rgba(35,26,21,.04), 0 8px 24px -16px rgba(35,26,21,.18); }
.cartao-hover { transition: transform .25s, box-shadow .25s, border-color .25s; }
.cartao-hover:hover { transform: translateY(-2px); border-color: #dcc7b2; box-shadow: 0 2px 4px rgba(35,26,21,.05), 0 18px 36px -18px rgba(35,26,21,.28); }
.rotulo { font-size: .7rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--mudo); }
.chip { display: inline-flex; align-items: center; gap: .35rem; font-size: .74rem; font-weight: 600; padding: .22rem .6rem; border-radius: 999px; white-space: nowrap; }
.chip-novo { background: #fdf0e3; color: #a35b1f; }
.chip-analise { background: #eef2fb; color: #3b5ba5; }
.chip-ok { background: #e7f3ee; color: var(--verde); }
.chip-alerta { background: #fbece7; color: var(--vermelho); }
.chip-neutro { background: #f3eee8; color: #6b5a4d; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; font-weight: 600; font-size: .87rem; border-radius: .75rem;
  padding: .62rem 1.05rem; transition: transform .15s, box-shadow .2s, background .2s, opacity .2s; cursor: pointer; white-space: nowrap; }
.btn:active { transform: scale(.98); }
.btn-cobre { background: linear-gradient(180deg, #cf8645, #b86d31); color: #fff; box-shadow: 0 6px 18px -8px rgba(196,122,60,.9), inset 0 1px 0 rgba(255,255,255,.25); }
.btn-cobre:hover { box-shadow: 0 10px 24px -8px rgba(196,122,60,1), inset 0 1px 0 rgba(255,255,255,.25); }
.btn-escuro { background: var(--carvao-800); color: #fff; }
.btn-escuro:hover { background: var(--carvao-700); }
.btn-claro { background: #fff; color: var(--tinta); border: 1px solid var(--linha); }
.btn-claro:hover { border-color: #d6c1ab; background: #fffaf4; }
.btn[disabled] { opacity: .45; pointer-events: none; }
:focus-visible { outline: 2px solid var(--cobre); outline-offset: 2px; }

/* views */
.vista { animation: entrar .45s cubic-bezier(.2,.7,.2,1); }
@keyframes entrar { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.aparecer { animation: entrar .5s cubic-bezier(.2,.7,.2,1) both; }

/* the morning hero: a technical drawing (elevation, crane, dimension lines) instead of a photo */
.heroi { position: relative; overflow: hidden; border-radius: 1.4rem; background: var(--carvao-900); color: #fff; }
.heroi::before { content: ""; position: absolute; inset: 0; background: var(--foto) right center/cover no-repeat; opacity: .9; transform: scale(1.04);
  animation: kenburns 24s ease-in-out infinite alternate; }
.heroi::after { content: ""; position: absolute; inset: 0; background: linear-gradient(100deg, rgba(20,14,11,.97) 0%, rgba(20,14,11,.86) 45%, rgba(20,14,11,.2) 100%); }
.heroi > * { position: relative; z-index: 1; }
@keyframes kenburns { from { transform: scale(1.04) translateX(0); } to { transform: scale(1.12) translateX(-2%); } }
.cursor::after { content: "▍"; color: var(--cobre-claro); animation: piscar 1s steps(2) infinite; margin-left: 1px; }
@keyframes piscar { 50% { opacity: 0; } }

/* 8 steps strip */
.passo-card { position: relative; }
.passo-card .n { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: .8rem;
  background: #fbf3ea; color: var(--cobre); border: 1px solid #f0dcc6; }
.passo-card:hover .n { background: var(--cobre); color: #fff; }

/* AI pipeline steps */
.etapa { display: flex; align-items: center; gap: .7rem; font-size: .86rem; color: var(--mudo); transition: color .3s; }
.etapa .bola { width: 22px; height: 22px; border-radius: 50%; border: 2px solid #e2d4c5; display: grid; place-items: center; flex: none; transition: all .3s; }
.etapa.ativa { color: var(--tinta); font-weight: 600; }
.etapa.ativa .bola { border-color: var(--cobre); border-top-color: transparent; animation: girar .7s linear infinite; }
.etapa.feita { color: var(--tinta); }
.etapa.feita .bola { border-color: var(--verde); background: var(--verde); }
.etapa.feita .bola::after { content: ""; width: 9px; height: 5px; border: 2px solid #fff; border-top: 0; border-right: 0; transform: rotate(-45deg) translate(1px, -1px); }
@keyframes girar { to { transform: rotate(360deg); } }

/* bars */
.barra { height: 6px; border-radius: 6px; background: #f1e7dc; overflow: hidden; }
.barra > i { display: block; height: 100%; border-radius: 6px; background: linear-gradient(90deg, var(--cobre-claro), var(--cobre)); width: 0; transition: width 1.1s cubic-bezier(.2,.7,.2,1); }
.barra.verde > i { background: linear-gradient(90deg, #5aa587, var(--verde)); }
.barra.vermelha > i { background: linear-gradient(90deg, #e07a5f, var(--vermelho)); }

/* floor plans drawn in SVG (app.js) */
.planta-svg { display: block; width: 100%; height: auto; }
.mini-planta svg { width: 100%; height: 100%; }
.pl-parede { fill: #3b2b22; }
.pl-divisao { fill: #fffdf9; }
.pl-vao { fill: #fffdf9; stroke: #3b2b22; stroke-width: 1; }
.pl-vidro { stroke: #8f7b6b; stroke-width: 1; fill: none; }
.pl-porta { stroke: #3b2b22; stroke-width: 1.6; fill: none; stroke-linecap: round; }
.pl-fino { fill: none; stroke: #a08b7a; stroke-width: .9; }
.pl-degrau { stroke: #c9b8a7; stroke-width: .9; fill: none; }
.pl-seta { stroke: #a08b7a; stroke-width: 1.1; fill: none; stroke-dasharray: 3 2; }
.pl-elev { fill: #f3ece4; stroke: #a08b7a; stroke-width: 1; }
.pl-exterior { fill: #f5f0e8; stroke: var(--verde); stroke-width: 1.4; stroke-dasharray: 6 4; }
.pl-piscina { fill: #d9ebe4; stroke: var(--verde); stroke-width: 1.6; }
.pl-cota { stroke: #b8a594; stroke-width: .9; fill: none; }
.pl-cota-t { fill: #8a7565; text-anchor: middle; font-family: Inter, system-ui, sans-serif; font-weight: 500; }
.pl-titulo { fill: var(--tinta); font-family: Inter, system-ui, sans-serif; font-weight: 700; letter-spacing: .08em; }
.pl-nome { fill: #5e4d41; text-anchor: middle; font-family: Inter, system-ui, sans-serif; font-weight: 600; }
.pl-area { fill: #a08b7a; text-anchor: middle; font-family: Inter, system-ui, sans-serif; font-weight: 500; }
.pl-rot-ext .pl-nome { fill: var(--verde); }
.pl-rot-ext .pl-area { fill: #5aa587; }

/* plan reading */
.planta-palco { position: relative; border-radius: 1rem; overflow: hidden; background: #fdfaf6; border: 1px solid var(--linha); }
.planta-palco .grelha { position: absolute; inset: 0; opacity: 0; transition: opacity .4s; pointer-events: none;
  background-image: linear-gradient(rgba(196,122,60,.10) 1px, transparent 1px), linear-gradient(90deg, rgba(196,122,60,.10) 1px, transparent 1px);
  background-size: 22px 22px; }
.planta-palco.a-ler .grelha { opacity: 1; }
.planta-palco .laser { position: absolute; left: 0; right: 0; height: 90px; top: -90px; pointer-events: none; opacity: 0;
  background: linear-gradient(180deg, transparent, rgba(227,165,107,.10) 60%, rgba(227,165,107,.55) 96%, #fff 100%);
  box-shadow: 0 6px 18px rgba(196,122,60,.6); }
.planta-palco.a-ler .laser { opacity: 1; animation: varrer 2.3s cubic-bezier(.45,.05,.55,.95) 2; }
.planta-palco.a-ler .pl-cota, .planta-palco.a-ler .pl-cota-t { animation: cota 1.1s ease-in-out 2; }
@keyframes cota { 50% { stroke: var(--cobre); fill: var(--cobre); } }
@keyframes varrer { from { top: -90px; } to { top: 100%; } }
.divisao { position: absolute; border: 2px solid var(--cobre); background: rgba(196,122,60,.10); border-radius: 6px; opacity: 0; transform: scale(.94);
  transition: opacity .35s, transform .35s; pointer-events: auto; }
.divisao.visivel { opacity: 1; transform: none; }
.divisao.exterior { border-style: dashed; border-color: var(--verde); background: rgba(47,107,85,.08); }
.divisao span { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); font-size: .64rem; font-weight: 600; line-height: 1.15; color: #fff;
  background: var(--cobre); padding: .2rem .45rem; border-radius: 6px; white-space: nowrap; text-align: center; box-shadow: 0 4px 10px -4px rgba(0,0,0,.45); }
.divisao span b { display: block; font-size: .72rem; font-weight: 800; }
.divisao.compacta span { padding: .1rem .3rem; }
.divisao.vertical span { transform: translate(-50%, -50%) rotate(-90deg); }
.divisao.linha span { padding: .08rem .45rem; }
.divisao.linha span b { display: inline; margin-left: .3rem; font-size: .66rem; }
.pl-rot, .pl-rot-ext { transition: opacity .5s; }
.planta-palco.com-caixas .pl-rot, .planta-palco.com-caixas .pl-rot-ext { opacity: .12; }
.divisao.compacta span b { font-size: .62rem; }
.divisao.exterior span { background: var(--verde); }
.divisao:hover { background: rgba(196,122,60,.22); z-index: 2; }
.zona-largar { border: 2px dashed #dcc6af; border-radius: 1rem; transition: all .2s; }
.zona-largar.por-cima { border-color: var(--cobre); background: #fbf3ea; }
.miniatura { border: 2px solid transparent; border-radius: .9rem; transition: all .2s; cursor: pointer; }
.miniatura:hover { border-color: #e8d3bd; }
.miniatura.ativa { border-color: var(--cobre); box-shadow: 0 8px 20px -12px rgba(196,122,60,.9); }

/* option toggles */
.seg { display: inline-flex; padding: 3px; border-radius: .7rem; background: #f3ece4; gap: 2px; flex-wrap: wrap; }
.seg button { font-size: .78rem; font-weight: 600; padding: .38rem .7rem; border-radius: .55rem; color: #6b5a4d; transition: all .2s; }
.seg button.on { background: #fff; color: var(--tinta); box-shadow: 0 1px 3px rgba(0,0,0,.08); }
.linha-orc { transition: background .6s; }
.linha-orc.mudou { background: #fff4e6; }

/* site sheets (the foreman's Excel) and the measurement certificate */
.excel { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.excel th { position: sticky; top: 0; z-index: 1; background: #f3eee8; color: #6b5a4d; font-weight: 600; font-size: 11px; text-align: left; padding: .42rem .5rem;
  border: 1px solid #e6dbcf; white-space: nowrap; }
.excel td { padding: .38rem .5rem; border: 1px solid #efe6dc; vertical-align: top; transition: background .4s; }
.excel td.n { background: #f8f4ef; color: #a08b7a; text-align: center; font-size: 11px; width: 30px; }
.excel tr.lida td { background: #fff7ee; }
.excel tr.lida td.n { background: #f6e7d6; color: var(--cobre); font-weight: 700; }
.tag-art { display: inline-block; font-size: 10.5px; font-weight: 700; color: #fff; background: var(--cobre); border-radius: 6px; padding: .05rem .4rem;
  white-space: nowrap; animation: entrar .35s both; }
.auto-acima { background: #fdf3ef; }
.auto-acima td:first-child { box-shadow: inset 3px 0 0 var(--vermelho); padding-left: .5rem; }

/* invoice */
.papel { background: #fff; border: 1px solid #e7ddd2; border-radius: .6rem; box-shadow: 0 30px 60px -30px rgba(35,26,21,.45); font-family: "Courier New", ui-monospace, monospace; position: relative; overflow: hidden; }
.realce { position: absolute; border: 2px solid var(--cobre); background: rgba(196,122,60,.16); border-radius: 5px; opacity: 0; transition: opacity .3s; box-shadow: 0 0 0 3px rgba(196,122,60,.15); }
.realce.visivel { opacity: 1; }
.papel .laser { position: absolute; left: 0; right: 0; height: 70px; top: -70px; opacity: 0;
  background: linear-gradient(180deg, transparent, rgba(227,165,107,.5)); }
.papel.a-ler .laser { opacity: 1; animation: varrer 1.6s ease-in-out 1; }

/* gantt */
.gantt-linha { display: grid; grid-template-columns: 230px 1fr; align-items: center; min-height: 46px; border-bottom: 1px dashed #efe5da; }
.gantt-pista { position: relative; height: 26px; }
.gantt-barra { position: absolute; top: 3px; height: 20px; border-radius: 6px; font-size: .66rem; font-weight: 600; color: #fff; padding: 0 .4rem; display: flex;
  align-items: center; overflow: hidden; white-space: nowrap; transform-origin: left; animation: crescer .9s cubic-bezier(.2,.7,.2,1) both; }
@keyframes crescer { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.f-lic { background: #9b8a7c; } .f-est { background: var(--cobre); } .f-env { background: #e09a5a; } .f-inst { background: #7a4a2a; } .f-acab { background: var(--verde); }
.hoje { position: absolute; top: -6px; bottom: -6px; width: 2px; background: var(--vermelho); border-radius: 2px; }
.hoje::before { content: "hoje"; position: absolute; top: -18px; left: -12px; font-size: .62rem; font-weight: 700; color: var(--vermelho); }
html[lang|="en"] .hoje::before { content: "today"; }
html[lang|="es"] .hoje::before { content: "hoy"; }

/* chat */
.bolha-ia { background: #fff; border: 1px solid var(--linha); border-radius: 1.1rem 1.1rem 1.1rem .3rem; }
.bolha-eu { background: var(--carvao-800); color: #fff; border-radius: 1.1rem 1.1rem .3rem 1.1rem; }
.wa .bolha-eu { background: #d9fdd3; color: #111; }
.wa .bolha-ia { background: #fff; border: 0; box-shadow: 0 1px 1px rgba(0,0,0,.08); }
.wa-fundo { background-color: #efeae2; background-image: radial-gradient(rgba(0,0,0,.035) 1px, transparent 1px); background-size: 14px 14px; }
.pontinhos span { width: 6px; height: 6px; border-radius: 50%; background: #b9a796; display: inline-block; margin: 0 1.5px; animation: saltar 1.2s infinite; }
.pontinhos span:nth-child(2) { animation-delay: .15s; } .pontinhos span:nth-child(3) { animation-delay: .3s; }
@keyframes saltar { 0%, 60%, 100% { transform: translateY(0); opacity: .5; } 30% { transform: translateY(-4px); opacity: 1; } }

/* how it works */
.no { border: 1px solid var(--linha); background: #fff; border-radius: .9rem; padding: .7rem .9rem; font-size: .85rem; font-weight: 600; }
.nucleo { background: radial-gradient(120% 120% at 50% 0%, #3b2b22, #1d1511); color: #fff; border-radius: 1.3rem; position: relative; overflow: hidden; }
.nucleo::after { content: ""; position: absolute; inset: -40%; background: conic-gradient(from 0deg, transparent, rgba(196,122,60,.35), transparent 30%);
  animation: girar 9s linear infinite; }
.nucleo > * { position: relative; z-index: 1; }
.fluxo { height: 2px; background: repeating-linear-gradient(90deg, var(--cobre) 0 8px, transparent 8px 14px); background-size: 28px 2px; animation: correr 1s linear infinite; }
@keyframes correr { to { background-position: 28px 0; } }

/* toasts */
#toasts { position: fixed; right: 22px; bottom: 22px; z-index: 80; display: flex; flex-direction: column; gap: 10px; }
.toast { background: var(--carvao-900); color: #fff; border-radius: .9rem; padding: .8rem 1rem; font-size: .86rem; box-shadow: 0 20px 40px -18px rgba(0,0,0,.6);
  display: flex; align-items: center; gap: .6rem; animation: entrar .35s both; max-width: 380px; }
.toast i { width: 8px; height: 8px; border-radius: 50%; background: #4ade80; flex: none; }

/* modal + proposal */
.modal-fundo { position: fixed; inset: 0; background: rgba(20,14,11,.62); backdrop-filter: blur(4px); z-index: 70; display: none; overflow-y: auto; padding: 32px 16px; }
.modal-fundo.aberto { display: block; animation: entrar .3s both; }
.folha { width: min(860px, 100%); margin: 0 auto; background: #fff; border-radius: 1rem; overflow: hidden; box-shadow: 0 40px 90px -30px rgba(0,0,0,.7); }

/* language switcher (PT · EN · ES), shared by the three versions of the demo */
.idiomas { display: inline-flex; align-items: center; gap: 2px; padding: 3px; flex: none; background: #fff; border: 1px solid var(--linha); border-radius: 999px; }
.idiomas a { font-size: .7rem; font-weight: 700; letter-spacing: .05em; line-height: 1; padding: .38rem .55rem; border-radius: 999px; color: var(--mudo);
  text-decoration: none; transition: background .15s, color .15s; }
.idiomas a:hover { color: var(--tinta); background: var(--creme); }
.idiomas a.ativo { background: var(--carvao-800); color: #fff; }

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: #dccbb9; border-radius: 10px; border: 2px solid var(--creme); }
::-webkit-scrollbar-track { background: transparent; }

@media (max-width: 640px) {
  #toasts { left: 16px; right: 16px; }
  .toast { max-width: none; }
}
@media (prefers-reduced-motion: reduce) {
  .heroi::before, .nucleo::after, .fluxo, .ponto-vivo { animation: none; }
}
/* printing the proposal: only the sheet, flowing over as many pages as it needs, with its colours */
@media print {
  body.com-proposta { height: auto !important; overflow: visible !important; background: #fff !important; }
  body.com-proposta > *:not(#modal-proposta) { display: none !important; }
  body.com-proposta #modal-proposta { position: static !important; display: block !important; padding: 0 !important; background: #fff !important;
    backdrop-filter: none !important; overflow: visible !important; animation: none !important; }
  .folha { box-shadow: none !important; border-radius: 0 !important; width: 100% !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .nao-imprimir { display: none !important; }
}

/* ---------- the business side (gestao.js): leads, quotes, clients, accounts ---------- */
.g-lead { display: grid; grid-template-columns: 30px minmax(0,1.5fr) 150px 112px 104px 40px minmax(0,1.7fr) 170px; gap: 4px 12px; align-items: center;
  padding: .7rem .25rem; border-bottom: 1px solid #f3ece4; }
.g-cab { font-size: 10.5px; text-transform: uppercase; letter-spacing: .08em; font-weight: 600; color: #a08b7a; border-bottom: 1px solid var(--linha); padding-block: .45rem; }
.g-nome:hover b { text-decoration: underline; text-underline-offset: 3px; }
.g-txt { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.g-ico { width: 30px; height: 30px; flex: none; border-radius: .6rem; border: 1px solid var(--linha); background: #fff; font-size: 13px; line-height: 1; color: #6b5a4d;
  transition: border-color .2s, background .2s; }
.g-ico:hover { border-color: #d6c1ab; background: #fffaf4; }
.g-avancar { flex: none; width: 28px; height: 28px; border-radius: .6rem; border: 1px solid #e3c4a5; background: #fdf0e3; color: #a35b1f; font-size: 11px; line-height: 1; }
.g-avancar:hover { background: var(--cobre); color: #fff; border-color: var(--cobre); }
.g-det { grid-column: 1 / -1; background: #faf6f1; border: 1px solid #f0e6da; border-radius: .9rem; padding: .9rem 1rem; margin: .4rem 0 .5rem; font-size: 13.5px;
  display: grid; gap: .5rem; color: #3b2b22; overflow-wrap: anywhere; }
.g-det b { font-weight: 600; }
.g-link { font-size: 13px; font-weight: 600; color: #a35b1f; }
.g-link:hover { color: var(--tinta); text-decoration: underline; }
.g-nota { width: 100%; min-height: 56px; padding: .5rem .7rem; border-radius: .7rem; border: 1px solid var(--linha); background: #fff; font: inherit; font-size: 13.5px; }
.g-editavel { outline: 2px dashed #e3c4a5; outline-offset: 4px; border-radius: .4rem; }
.g-prop { display: grid; grid-template-columns: minmax(0,1.1fr) minmax(0,1.6fr) 110px 200px 100px 168px; gap: 4px 14px; align-items: center; padding: .7rem .25rem;
  border-bottom: 1px solid #f3ece4; }
.g-mes { min-width: 50px; padding: .3rem .45rem; border-radius: .55rem; border: 1px solid #ece2d7; font-size: 11.5px; line-height: 1.25; text-align: center; color: #a08b7a;
  font-weight: 600; font-variant-numeric: tabular-nums; }
.g-mes small { display: block; font-size: 10.5px; font-weight: 500; }
.mc-paga { background: #e7f3ee; border-color: #b9dccb; color: #24563f; }
.mc-receber { background: #fdf3e2; border-color: #f0d3a0; color: #8a5a12; }
.mc-vencida { background: #fbece7; border-color: #eab5a4; color: #9b3a22; }
.mc-falta { background: #fff; border-color: var(--vermelho); color: #9b3a22; }
.mc-agora { background: #fff; border: 1px dashed #c9a27e; color: var(--tinta); }
.mc-seguir { background: transparent; border: 1px dashed #e0d3c5; color: #a08b7a; }
@media (max-width: 1100px) {
  .g-lead { grid-template-columns: 26px minmax(0,1fr) auto; gap: 4px 10px; }
  .g-lead.g-cab, .g-prop.g-cab { display: none; }
  .g-lead > :nth-child(1) { grid-column: 1; grid-row: 1; }
  .g-lead > :nth-child(2) { grid-column: 2; grid-row: 1; }
  .g-lead > :nth-child(5) { grid-column: 3; grid-row: 1; }
  .g-lead > :nth-child(3) { grid-column: 2; grid-row: 2; }
  .g-lead > :nth-child(4) { grid-column: 3; grid-row: 2; }
  .g-lead > :nth-child(6) { display: none; }
  .g-lead > :nth-child(7) { grid-column: 2 / -1; grid-row: 3; }
  .g-lead > :nth-child(8) { grid-column: 2 / -1; grid-row: 4; justify-content: flex-start; }
  .g-lead > .g-det { grid-column: 1 / -1; grid-row: 5; }
  .g-prop { grid-template-columns: minmax(0,1fr) auto; gap: 4px 10px; }
  .g-prop > :nth-child(1) { grid-column: 1; grid-row: 1; }
  .g-prop > :nth-child(3) { grid-column: 2; grid-row: 1; }
  .g-prop > :nth-child(2) { grid-column: 1 / -1; grid-row: 2; }
  .g-prop > :nth-child(4) { grid-column: 1; grid-row: 3; }
  .g-prop > :nth-child(5) { grid-column: 2; grid-row: 3; }
  .g-prop > :nth-child(6) { grid-column: 1 / -1; grid-row: 4; justify-content: flex-start; }
}
.g-tile { container-type: inline-size; }
.g-val { font-size: 26px; font-size: clamp(14px, 12.5cqi, 26px); line-height: 1.25; }
.g-val-p { font-size: 22px; font-size: clamp(14px, 12cqi, 22px); }

/* ---------- the owner's net worth (patrimonio.js) ---------- */
.p-comp-barra { display: flex; height: 14px; border-radius: 7px; overflow: hidden; gap: 2px; margin-bottom: 16px; }
.p-comp-barra span { display: block; height: 100%; min-width: 3px; }
.p-comp-lista { display: grid; grid-template-columns: auto minmax(0,1fr) auto auto; gap: 8px 12px; align-items: center; font-size: 13.5px; }
.p-comp-lista i { width: 11px; height: 11px; border-radius: 3px; display: inline-block; }
.p-comp-lista .v { font-weight: 600; font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; }
.p-comp-lista .p { color: var(--mudo); font-variant-numeric: tabular-nums; text-align: right; min-width: 44px; }
.p-lista { container-type: inline-size; }
.p-grupo + .p-grupo { margin-top: 18px; }
.p-grupo-cab { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 6px 4px; border-bottom: 1px solid var(--linha);
  font-size: 10.5px; font-weight: 600; color: #a08b7a; text-transform: uppercase; letter-spacing: .08em; }
.p-grupo-cab b { color: var(--tinta); font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: 0; text-transform: none; font-size: 13px; }
.p-ativo { display: grid; grid-template-columns: 34px minmax(0,1.5fr) minmax(0,1.3fr) 120px 68px; gap: 4px 12px; align-items: center; padding: 10px 4px;
  border-bottom: 1px solid #f3ece4; font-size: 13.5px; }
.p-ativo b { display: block; font-weight: 600; }
.p-ativo small { display: block; color: var(--mudo); font-size: 12px; }
.p-ico { width: 32px; height: 32px; flex: none; border-radius: .6rem; display: inline-flex; align-items: center; justify-content: center; background: #faf6f1;
  border: 1px solid #f0e6da; color: #a35b1f; }
.p-fonte { font-size: 12.5px; color: #5b4b40; min-width: 0; }
.p-v { text-align: right; font-weight: 600; font-size: 14.5px; white-space: nowrap; }
.p-divida .p-v { color: var(--vermelho); }
.p-divida .p-ico { color: var(--vermelho); }
.p-acoes { display: flex; gap: 4px; justify-content: flex-end; }
@container (max-width: 620px) {
  .p-ativo { grid-template-columns: 34px minmax(0,1fr) auto; gap: 2px 10px; }
  .p-ativo .p-ico { grid-row: 1 / 3; }
  .p-ativo .p-fonte { grid-column: 2 / -1; grid-row: 2; }
  .p-ativo .p-acoes { grid-column: 2 / -1; grid-row: 3; justify-content: flex-start; margin-top: 4px; }
}
.p-tipos { display: grid; grid-template-columns: repeat(auto-fill, minmax(165px, 1fr)); gap: 8px; margin-bottom: 14px; }
.p-tipos button { display: grid; grid-template-columns: auto minmax(0,1fr); column-gap: 10px; align-items: center; text-align: left; padding: 9px 11px;
  border-radius: .8rem; border: 1px solid var(--linha); background: #fff; transition: border-color .2s, background .2s; }
.p-tipos button .p-ico { grid-row: 1 / 3; }
.p-tipos button b { font-weight: 600; font-size: 13.5px; }
.p-tipos button small { font-size: 11.5px; color: var(--mudo); }
.p-tipos button:hover, .p-tipos button[aria-pressed="true"] { border-color: #e3c4a5; background: #fffaf4; }
.p-form { display: grid; gap: 12px; padding: 16px; border: 1px solid #f0e6da; border-radius: .9rem; background: #faf6f1; }
.p-campos { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px 12px; }
.p-campo { display: grid; gap: 4px; font-size: 12px; font-weight: 600; color: var(--mudo); min-width: 0; }
.p-largo { grid-column: 1 / -1; }
.p-linha { display: flex; gap: 8px; }
.p-linha input { flex: 1; }
.p-campo input, .p-campo select { width: 100%; min-width: 0; padding: .5rem .7rem; border-radius: .7rem; border: 1px solid var(--linha); background: #fff; color: var(--tinta);
  font: inherit; font-size: 14px; font-weight: 400; }
.p-campo input:focus, .p-campo select:focus { border-color: var(--cobre); }
@media (max-width: 640px) { .p-campo input, .p-campo select { font-size: 16px; } }
.p-resultados { display: grid; gap: 6px; }
.p-resultados:empty { display: none; }
.p-resultados button { text-align: left; padding: .5rem .8rem; border-radius: .7rem; border: 1px solid var(--linha); background: #fff; font-size: 13.5px; }
.p-resultados button:hover { border-color: #e3c4a5; background: #fffaf4; }
.p-estimativa, .p-comparaveis:not(:empty) { padding: 12px 14px; border-radius: .8rem; border: 1px solid #f0dcc6; background: #fbf3ea; font-size: 13.5px; color: #3b2b22; }
.p-comparaveis:not(:empty) { border-color: #c9d6ef; background: #eef2fb; }
.p-estimativa b, .p-comparaveis b { font-size: 18px; font-weight: 600; font-variant-numeric: tabular-nums; }
.p-lido { font-size: 12.5px; color: var(--verde); }
.p-lido:empty { display: none; }
