:root {
  --bg: #f4f7f3; --panel: #ffffff; --ink: #17261c; --muted: #5f6f64; --line: #dfe7df;
  --green: #1f7a4a; --green-2: #2e9c61; --green-soft: #e3f3e8; --gold: #c9a227; --gold-soft: #fbf3d6;
  --red: #b3402f; --red-soft: #fbe6e2; --blue-soft: #e6eefb;
  --radius: 14px; --shadow: 0 1px 2px rgba(20,40,25,.06), 0 4px 16px rgba(20,40,25,.06);
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #0f1612; --panel: #16201a; --ink: #e5efe7; --muted: #9db0a3; --line: #26342b;
    --green: #3fb574; --green-2: #58c98a; --green-soft: #1b3325; --gold: #e0bd4a; --gold-soft: #2e2915;
    --red: #ef7b66; --red-soft: #3a1f1a; --blue-soft: #1a2536; }
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { font: 15px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; background: var(--bg); color: var(--ink); }
.hidden { display: none !important; }
button, input, select, textarea { font: inherit; color: inherit; }
.btn { border: 1px solid var(--line); background: var(--panel); padding: 7px 12px; border-radius: 10px; cursor: pointer; }
.btn:hover { border-color: var(--green-2); }
.btn.primary { background: var(--green); border-color: var(--green); color: #fff; }
.btn.primary:hover { background: var(--green-2); }
.btn.gold { background: var(--gold-soft); border-color: var(--gold); }
.btn.danger { color: var(--red); }
.btn.small { padding: 4px 9px; font-size: 13px; }
.btn.big { padding: 12px 22px; font-size: 16px; text-decoration: none; display: inline-block; }
.btn:disabled { opacity: .5; cursor: default; }

.login { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 24px; gap: 6px; }
.login-mascot { width: 180px; filter: drop-shadow(0 8px 18px rgba(31,122,74,.25)); }
.login h1 { margin: 6px 0 0; color: var(--green); font-size: 34px; }
.login p { color: var(--muted); margin: 0 0 14px; }

.app { height: 100%; display: flex; flex-direction: column; }
.top { background: var(--panel); border-bottom: 1px solid var(--line); padding: 8px 12px 0; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; }
.logo { width: 38px; height: 38px; object-fit: contain; }
.who { display: flex; flex-direction: column; line-height: 1.15; margin-right: auto; }
.who strong { color: var(--green); font-size: 17px; }
.who span { color: var(--muted); font-size: 12px; }
nav { display: flex; gap: 2px; overflow-x: auto; width: 100%; scrollbar-width: none; }
nav button { border: 0; background: none; padding: 9px 10px; border-bottom: 3px solid transparent; cursor: pointer; white-space: nowrap; color: var(--muted); }
nav button.active { color: var(--green); border-bottom-color: var(--green); font-weight: 600; }
.pill { background: var(--red); color: #fff; border-radius: 99px; padding: 0 6px; font-size: 11px; margin-left: 3px; }

main { flex: 1; min-height: 0; }
.tab { display: none; height: 100%; overflow-y: auto; padding: 14px; }
.tab.active { display: block; }
#tab-chat.active { display: flex; flex-direction: column; padding: 0; }
h2 { font-size: 18px; margin: 0; }
h3 { font-size: 14px; margin: 20px 0 8px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.muted { color: var(--muted); }
.section-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.section-head h2 { margin-right: auto; }

.chat-bar { display: flex; gap: 8px; align-items: center; padding: 8px 12px; border-bottom: 1px solid var(--line); background: var(--panel); }
.chat-bar select { flex: 1; min-width: 0; padding: 6px; border-radius: 8px; border: 1px solid var(--line); background: var(--panel); }
.ctx { font-size: 12px; color: var(--muted); white-space: nowrap; }
.messages { flex: 1; overflow-y: auto; padding: 14px 12px; display: flex; flex-direction: column; gap: 10px; }
.msg { max-width: 88%; padding: 9px 12px; border-radius: var(--radius); box-shadow: var(--shadow); word-wrap: break-word; }
.msg.user { align-self: flex-end; background: var(--green); color: #fff; border-bottom-right-radius: 4px; white-space: pre-wrap; }
.msg.assistant { align-self: flex-start; background: var(--panel); border-bottom-left-radius: 4px; }
.msg.assistant p { margin: 0 0 6px; } .msg.assistant p:last-child { margin: 0; }
.msg.assistant ul, .msg.assistant ol { margin: 4px 0 6px; padding-left: 20px; }
.msg .meta { font-size: 11px; color: var(--muted); margin-top: 6px; }
.msg.thinking { color: var(--muted); display: flex; align-items: center; gap: 8px; }
.msg.thinking img { width: 26px; animation: bob 1s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(-4px) rotate(-4deg); } }
.empty { margin: auto; text-align: center; color: var(--muted); width: 100%; max-width: 560px; min-width: 0; }
.empty img { width: 120px; }
.suggest { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin-top: 10px; }
.suggest button { border: 1px solid var(--line); background: var(--panel); border-radius: 99px; padding: 6px 11px; cursor: pointer; font-size: 13px; }
.suggest button:hover { border-color: var(--green-2); color: var(--green); }
.composer { display: flex; gap: 6px; padding: 10px 12px; border-top: 1px solid var(--line); background: var(--panel); align-items: flex-end; }
.composer textarea { flex: 1; resize: none; border: 1px solid var(--line); border-radius: 12px; padding: 9px 11px; max-height: 160px; background: var(--bg); }
.icon { border: 1px solid var(--line); background: var(--panel); border-radius: 10px; padding: 7px 9px; cursor: pointer; }
.icon.rec { background: var(--red-soft); border-color: var(--red); }

.list { display: flex; flex-direction: column; gap: 8px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 11px 13px; box-shadow: var(--shadow); }
.card .row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.card .title { font-weight: 600; margin-right: auto; }
.card .sub { color: var(--muted); font-size: 13px; margin-top: 3px; }
.card .actions { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 9px; }
.tag { font-size: 11px; padding: 2px 8px; border-radius: 99px; background: var(--green-soft); color: var(--green); font-weight: 600; }
.tag.warn { background: var(--gold-soft); color: #8a6d0b; } .tag.bad { background: var(--red-soft); color: var(--red); }
.tag.info { background: var(--blue-soft); color: #3565b5; }
@media (prefers-color-scheme: dark) { .tag.warn { color: var(--gold); } .tag.info { color: #8fb0ea; } }
.card.late { border-left: 4px solid var(--red); }
.card.current { border: 2px solid var(--green); }
.inline-form { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.inline-form input { flex: 1; min-width: 140px; padding: 7px 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); }
select { padding: 6px 8px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel); }
table { width: 100%; border-collapse: collapse; background: var(--panel); border-radius: var(--radius); overflow: hidden; font-size: 14px; }
th, td { text-align: left; padding: 7px 9px; border-bottom: 1px solid var(--line); }
th { font-size: 12px; color: var(--muted); font-weight: 600; }
td.num { text-align: right; font-variant-numeric: tabular-nums; }
.table-wrap { overflow-x: auto; }
.prose { white-space: pre-wrap; }
.toast { position: fixed; bottom: 16px; left: 50%; transform: translateX(-50%); background: var(--ink); color: var(--bg); padding: 9px 16px; border-radius: 10px; box-shadow: var(--shadow); z-index: 10; max-width: 90%; }
a.btn { text-decoration: none; }

.hidden-feature { display: none !important; }

.unatt { box-sizing: border-box; width: 100%; max-width: 520px; min-width: 0; overflow: hidden; margin: 4px auto 14px; text-align: left; background: var(--panel); border: 1px solid var(--line);
  border-left: 4px solid var(--red); border-radius: var(--radius); padding: 10px 12px; box-shadow: var(--shadow); }
.unatt h4 { margin: 0 0 6px; font-size: 14px; display: flex; align-items: flex-start; gap: 6px; color: var(--ink); }
.unatt h4 .n { background: var(--red); color: #fff; border-radius: 999px; padding: 0 7px; font-size: 12px; }
.unatt ul { list-style: none; margin: 0; padding: 0; max-height: 220px; overflow: auto; }
.unatt li { display: flex; gap: 8px; align-items: center; padding: 6px 4px; border-top: 1px solid var(--line); cursor: pointer; border-radius: 8px; }
.unatt li:hover { background: var(--red-soft); }
.unatt li .who { flex: 1; min-width: 0; }
.unatt li .who b { display: block; font-size: 13.5px; }
.unatt li .who span { display: block; font-size: 12px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.unatt li .t { font-size: 12px; font-weight: 600; color: var(--red); white-space: nowrap; display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.unatt li .ciente { font-weight: 500; color: var(--ink); padding: 2px 8px; font-size: 11.5px; }
.unatt.ok { border-left-color: var(--green); }
.unatt li .obs { color: var(--ink) !important; font-weight: 500; white-space: normal !important; }
.unatt h4 .n.gray { background: var(--muted); }
.unatt ul.closed li .t { color: var(--muted); }
.unatt ul.closed li:hover { background: var(--bg); }

.unatt.unatt-full { max-width: none; margin: 0; }
.unatt.unatt-full ul { max-height: none; }

/* popup da cotação de carro */
.aq-modal { position: fixed; inset: 0; background: rgba(0,0,0,.45); display: flex; align-items: flex-end; justify-content: center; z-index: 50; padding: 12px; }
.aq-modal.hidden { display: none; }
.aq-box { background: var(--panel); color: var(--ink); width: 100%; max-width: 560px; max-height: 88vh; display: flex; flex-direction: column; border-radius: 14px; border: 1px solid var(--line); box-shadow: 0 10px 40px rgba(0,0,0,.25); }
@media (min-width: 640px) { .aq-modal { align-items: center; } }
.aq-head { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px 0; }
.aq-head h3 { margin: 0; font-size: 16px; color: var(--ink); text-transform: none; letter-spacing: 0; }
#aq-sub { margin: 2px 14px 8px; font-size: 12.5px; }
.aq-body { overflow: auto; padding: 0 10px; flex: 1; min-height: 80px; }
.aq-opt { display: flex; gap: 10px; align-items: flex-start; border: 1px solid var(--line); border-radius: 10px; padding: 9px 10px; margin-bottom: 8px; cursor: pointer; }
.aq-opt:hover { border-color: var(--green-2); }
.aq-opt:has(input:checked) { border-color: var(--green); background: var(--green-soft); }
.aq-opt.off { opacity: .6; cursor: default; }
.aq-opt.done { cursor: default; }
.aq-opt input { margin-top: 3px; width: 17px; height: 17px; accent-color: var(--green); flex: none; }
.aq-main { flex: 1; min-width: 0; font-size: 13px; }
.aq-top { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.aq-top b { font-size: 14px; }
.aq-price { font-weight: 700; color: var(--green); white-space: nowrap; }
.aq-price small { font-weight: 400; color: var(--muted); }
.aq-keys { display: flex; gap: 8px; margin-top: 6px; }
.aq-keys span { flex: 1; border: 1px solid var(--line); border-radius: 8px; padding: 4px 8px; background: var(--panel); }
.aq-keys small { display: block; font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .03em; }
.aq-keys b { font-size: 16px; color: var(--ink); }
.aq-pay { margin-top: 4px; font-size: 12px; color: var(--muted); }
.aq-main details { margin-top: 4px; font-size: 12px; }
.aq-main summary { cursor: pointer; color: var(--green); }
.aq-cov { color: var(--muted); margin-top: 3px; }
.aq-foot { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 10px 14px; border-top: 1px solid var(--line); font-size: 12.5px; }
.aq-card button { margin-top: 6px; }
.aq-carrier { display: inline-block; margin-top: 6px; font-size: 12.5px; font-weight: 600; color: var(--green); text-decoration: none; border: 1px solid var(--line); border-radius: 8px; padding: 3px 8px; }
.aq-carrier:hover { border-color: var(--green-2); background: var(--green-soft); }

/* ---------------- Financeiro (paleta de dados validada: categórica fixa por modelo) */
.viz-root { --s1:#2a78d6; --s2:#eb6834; --s3:#1baf7a; --s4:#eda100; --s5:#e87ba4; --s6:#008300; --s7:#4a3aa7; --s8:#e34948; --bar:#2a78d6; }
@media (prefers-color-scheme: dark) {
  .viz-root { --s1:#3987e5; --s2:#d95926; --s3:#199e70; --s4:#c98500; --s5:#d55181; --s6:#008300; --s7:#9085e9; --s8:#e66767; --bar:#3987e5; }
}
.fin-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; margin: 10px 0 14px; }
.fin-tile { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.fin-tile .k { font-size: 12px; color: var(--muted); }
.fin-tile .v { font-size: 24px; font-weight: 700; color: var(--ink); line-height: 1.2; }
.fin-tile .s { font-size: 11.5px; color: var(--muted); }
.fin-chart { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 8px; overflow-x: auto; }
.fin-chart svg text { fill: var(--muted); font-size: 11px; }
.fin-chart .grid { stroke: var(--line); stroke-width: 1; }
.fin-legend { display: flex; flex-wrap: wrap; gap: 10px; font-size: 12.5px; margin: 4px 0 6px; color: var(--ink); }
.fin-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
.fin-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; margin-top: 10px; }
.fin-bars { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 8px 10px; }
.fin-bar { display: grid; grid-template-columns: minmax(70px, 38%) 1fr auto; gap: 8px; align-items: center; font-size: 12.5px; padding: 3px 0; }
.fin-bar .lbl { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink); }
.fin-bar .trk { height: 10px; }
.fin-bar .fil { height: 10px; border-radius: 0 4px 4px 0; background: var(--bar); min-width: 2px; }
.fin-bar .val { color: var(--ink); font-variant-numeric: tabular-nums; }
.fin-tip { position: fixed; z-index: 50; background: var(--panel); color: var(--ink); border: 1px solid var(--line); border-radius: 8px;
  padding: 6px 9px; font-size: 12px; box-shadow: var(--shadow); pointer-events: none; }
.fin-prices input { width: 80px; }

.fin-off { border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; margin: 8px 0 12px; background: var(--panel); }
.fin-off .fin-tiles { margin: 8px 0; }

/* Admin em sanfona */
details.acc { border: 1px solid var(--line); border-radius: 12px; background: var(--panel); margin: 8px 0; padding: 0 12px; }
details.acc > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 8px; padding: 10px 0; }
details.acc > summary::-webkit-details-marker { display: none; }
details.acc > summary::before { content: "▸"; color: var(--muted); transition: transform .15s; }
details.acc[open] > summary::before { transform: rotate(90deg); }
details.acc > summary > h2, details.acc > summary > h3 { margin: 0; font-size: 15px; font-weight: 700; text-transform: none; letter-spacing: 0; color: var(--ink); }
details.acc[open] { padding-bottom: 12px; }

/* arrastar arquivo para a conversa */
#tab-chat.drop { outline: 2px dashed var(--accent, #1a7f4b); outline-offset: -6px; }

/* ---- módulo do gestor: paleta própria (agentes continuam no verde) ---- */
html[data-cor="marinho"] { --green: #1f4e8c; --green-2: #2f6cb8; --green-soft: #e4ecf8; }
html[data-cor="roxo"] { --green: #5b3aa8; --green-2: #7653c9; --green-soft: #eee8fa; }
html[data-cor="grafite"] { --green: #33393f; --green-2: #a8851a; --green-soft: #f3edd9; }
@media (prefers-color-scheme: dark) {
  html[data-cor="marinho"] { --green: #6fa3e6; --green-2: #8db8f0; --green-soft: #18263a; }
  html[data-cor="roxo"] { --green: #a98ae8; --green-2: #bfa4f0; --green-soft: #261c3a; }
  html[data-cor="grafite"] { --green: #d6b34a; --green-2: #e6c768; --green-soft: #2b2617; }
}
html[data-cor] header { border-bottom: 3px solid var(--green); }
.gest { margin-bottom: 10px; }
.gest summary { cursor: pointer; }
.gform { display: flex; flex-direction: column; gap: 8px; margin-top: 10px; }
.gform input:not([type=checkbox]), .gform textarea, .gform > select { width: 100%; }
.g-dest .g-pick label { justify-content: flex-start; }
.g-dest .g-pick input { width: auto; margin: 0; flex: none; }
.g-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: end; }
.g-row label { display: flex; flex-direction: column; gap: 3px; font-size: 12px; color: var(--muted); }
.g-row label input, .g-row label select { width: auto; }
.g-dest .g-pick { max-height: 150px; overflow: auto; border: 1px solid var(--line); border-radius: 8px; padding: 6px 8px; margin-top: 6px; }
.g-dest .g-pick label { display: flex; gap: 6px; align-items: center; font-size: 13px; padding: 2px 0; }
.g-people { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.g-people span { font-size: 11px; padding: 2px 7px; border-radius: 99px; background: var(--red-soft); }
.g-people span.ok { background: var(--green-soft); }
#com-banner, #pausa-banner { padding: 8px 10px; background: var(--gold-soft); border-bottom: 2px solid var(--gold); }
#com-banner .com, #pausa-banner .com { background: var(--panel); border: 1px solid var(--gold); border-radius: 12px; padding: 10px 12px; margin-bottom: 6px; }
#com-banner .com b, #pausa-banner .com b { display: block; margin-bottom: 4px; }
#com-banner .com p { margin: 0 0 8px; white-space: pre-wrap; }
/* plantão (13/10) */
.gform label.chk { display: flex; align-items: center; gap: 6px; }
.gform label.chk input { width: auto; }
#g-pl-list .g-row select { max-width: 220px; }
#pl-info code { word-break: break-all; font-size: 11px; }

/* 15/10: ligação tocando no ramal — cobre a tela até atender ou parar de tocar */
@keyframes ring-pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(31,122,74,.5); } 50% { box-shadow: 0 0 0 14px rgba(31,122,74,0); } }
#ring-overlay { position: fixed; inset: 0; z-index: 9999; display: flex; align-items: center; justify-content: center; background: rgba(10,20,40,.55); padding: 16px; }
#ring-overlay.hidden { display: none; }
#ring-overlay .ring-card { background: var(--panel); border: 3px solid #1f7a4a; border-radius: 18px; padding: 20px; width: min(440px, 100%); animation: ring-pulse 1.4s ease-in-out infinite; }
#ring-overlay .ring-tag { font-weight: 700; font-size: 12px; text-transform: uppercase; color: #1f7a4a; margin-bottom: 6px; }
#ring-overlay h2 { margin: 0 0 6px; }
#ring-overlay .ring-card.urgente { border-color: #c0392b; }
#ring-overlay .ring-card.urgente .ring-tag { color: #c0392b; }
#ring-overlay .row { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-top: 10px; }

/* 15/10: aba Relatórios */
.rp-bar { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; margin-bottom: 6px; }
.rp-kpis { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 6px; margin: 8px 0 12px; }
.rp-kpi { background: var(--panel); border: 1px solid var(--line, #d0d7de); border-radius: 10px; padding: 8px; text-align: center; }
.rp-kpi b { display: block; font-size: 20px; }
.rp-kpi span { font-size: 11px; opacity: .75; }
.rp-kpi.bad b { color: #c0392b; }
.rp-al.g3 { border-left: 4px solid #c0392b; }
.rp-al.g2 { border-left: 4px solid #e0a100; }
.rp-al.g1 { border-left: 4px solid #8899aa; }
.rp-acts { gap: 6px; justify-content: flex-start; margin-top: 4px; }
.rp-tab { width: 100%; border-collapse: collapse; font-size: 13px; }
.rp-tab th, .rp-tab td { padding: 4px 6px; border-bottom: 1px solid var(--line, #d0d7de); text-align: left; }
.rp-tr { white-space: pre-wrap; max-height: 260px; overflow: auto; font-size: 12px; background: var(--bg2, #f6f8fa); padding: 8px; border-radius: 8px; }
.rp-grp { border: 1px solid var(--line, #d0d7de); border-radius: 10px; padding: 4px 8px; margin: 6px 0; background: var(--panel); }
.rp-grp > summary { cursor: pointer; padding: 4px 0; }
.rp-ag { cursor: pointer; }
.rp-ag:hover { background: var(--bg2, #f6f8fa); }
.rp-lgtab td { vertical-align: top; }
.rp-lgtab .rp-acts { display: flex; gap: 4px; }
.rp-det-row td { background: var(--bg2, #f6f8fa); }

/* 15/10: avisos e alertas em sanfona (assunto → hoje / antes de hoje) e tabelas compactas */
.nt-sub { margin: 4px 0 4px 8px; border-left: 3px solid var(--line, #d0d7de); padding-left: 8px; }
.nt-sub > summary { cursor: pointer; padding: 3px 0; font-weight: 600; }
.nt-cat > summary .btn { margin-left: 6px; }
.nt-tab td.nt-h { white-space: nowrap; width: 1%; color: var(--muted, #667); }
.nt-tab td.nt-a { width: 1%; white-space: nowrap; text-align: right; }
.nt-tab tr.lido { opacity: .6; }
.nt-tab .nt-t { color: inherit; text-decoration: none; font-weight: 600; }
.nt-tab .nt-t:hover { text-decoration: underline; }
.pill.bad { background: #c0392b; color: #fff; }
.rp-altab td { vertical-align: top; }
.rp-altab tr.rp-al.g3 td:first-child { color: #c0392b; }
.sub.ok, tr.ok td { color: #1f7a4a; }
tr.warn td { color: #9a6700; }
.c360-bar { display: flex; gap: 6px; margin: 8px 0; }
.c360-bar input { flex: 1; }
.c360 h3 { font-size: 16px; }
.pill.warn { background: #9a6700; color: #fff; }

/* 16/10: ✕ do cartão urgente */
.ring-card { position: relative; }
.ring-x { position: absolute; top: 8px; right: 10px; border: 0; background: transparent; font-size: 20px; line-height: 1; color: var(--muted); cursor: pointer; padding: 4px 8px; border-radius: 8px; }
.ring-x:hover { background: var(--line); color: var(--ink); }

/* 16/10: desempenho da equipe */
.dz-tab td.num, .dz-tab th { text-align: center; }
.dz-tab td:first-child, .dz-tab th:first-child { text-align: left; }
.dz-tab tr.muted td { color: var(--muted); }
.dz-tab tr.dz-tot td { border-top: 2px solid var(--line); background: var(--green-soft); }

/* 17/10: agente 360 (dia / semana / mês / ano) */
.a360-bar { flex-wrap: wrap; align-items: center; }
.a360-bar select { flex: 1; min-width: 180px; }
.a360-per { display: inline-flex; gap: 2px; }
.a360-per .btn.on { background: var(--accent, #2e9c61); color: #fff; }
.a360 { border: 1px solid var(--line, #d0d7de); border-radius: 12px; padding: 10px 12px; margin: 6px 0 14px; background: var(--panel); }
.a360 h4 { margin: 12px 0 4px; font-size: 14px; }
.a360-serie { display: flex; align-items: flex-end; gap: 2px; height: 70px; margin: 6px 0 2px; }
.a360-serie div { flex: 1; background: var(--accent, #2e9c61); border-radius: 3px 3px 0 0; min-height: 1px; opacity: .85; }
.a360-serie div.l { background: #6aa8e8; }
.a360-eixo { display: flex; justify-content: space-between; font-size: 10px; opacity: .7; }

/* 23/10: aba Reuniões */
.meet-det { margin-top: 8px; border-top: 1px solid var(--line); padding-top: 8px; }
.meet-det h4 { margin: 10px 0 4px; font-size: 13px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.meet-det ul { margin: 0; padding-left: 20px; }
.meet-tr { white-space: pre-wrap; font: 13px/1.45 system-ui, sans-serif; max-height: 360px; overflow: auto; background: var(--bg); padding: 8px; border-radius: 8px; }

/* 23/10: sanfonas da aba Equipe (comunicados / tarefas enviados) */
.g-acc-opt { display: inline-flex; gap: 6px; align-items: center; font-size: 13px; color: var(--muted); margin: 8px 0; }
.g-com-det { margin-top: 8px; border-top: 1px solid var(--line); padding-top: 8px; }
.g-com-txt { white-space: pre-wrap; font-size: 14px; margin-bottom: 8px; }

/* 23/10: tabelas nas respostas do Drako */
.md-tab { overflow-x: auto; margin: 6px 0; }
.md-tab table { border-collapse: collapse; font-size: 13px; }
.md-tab th, .md-tab td { border: 1px solid var(--line); padding: 4px 8px; text-align: left; vertical-align: top; }
.md-tab th { background: var(--green-soft); }

/* 24/10: mapa mental do cliente */
.mapa-mini { border: 1px solid var(--line); border-radius: 10px; overflow: hidden; cursor: zoom-in; background: #f8fafc; margin: 4px 0 6px; }
.mapa-mini svg, .mapa-svg svg { width: 100%; height: auto; display: block; }
.mapa-bar { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.aq-box.mapa-box { max-width: min(1200px, 96vw); max-height: 94vh; }
.mapa-svg { padding: 0 14px; }
.mapa-ia { width: 100%; border-radius: 10px; border: 1px solid var(--line); cursor: zoom-in; margin: 6px 0; display: block; }

/* 28/10: arquivos do computador */
.pc-item { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; width: 100%; text-align: left; border: 1px solid var(--line); background: var(--panel); color: var(--ink); border-radius: 10px; padding: 8px 10px; margin-bottom: 6px; cursor: pointer; }
.pc-item:hover { border-color: var(--green-2); }
.pc-item.off { opacity: .55; cursor: default; }
.pc-nome { font-weight: 600; word-break: break-word; }
