/* Ferramentas de venda da central: dashboard, metas e ranking, previsão, catálogo, robô (pagamento, fluxo de entrada, remarketing, VIP) e SDR. Arquivo próprio para não misturar com app.css/atendimento.css. */
.viz-root { --series-1: #2a78d6; --series-2: #eb6834; --viz-outros: #b9b7b0; --viz-grade: rgba(0,0,0,.08); }
@media (prefers-color-scheme: dark) { :root:where(:not([data-theme="light"])) .viz-root { --series-1: #3987e5; --series-2: #d95926; --viz-outros: #5a5955; --viz-grade: rgba(255,255,255,.08); } }
:root[data-theme="dark"] .viz-root { --series-1: #3987e5; --series-2: #d95926; --viz-outros: #5a5955; --viz-grade: rgba(255,255,255,.08); }
/* 🧠 SDR + Closer */
.sdr-barra { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px 14px 0; }
.sdr-bt { background: linear-gradient(135deg, #6A1B9A, var(--series-1)) !important; color: #fff !important; border: 0 !important; font-weight: 700; }
.sdr-cfg { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 10px; margin: 10px 0; }
.sdr-cfg label { display: flex; flex-direction: column; gap: 4px; font-size: 12px; }
.sdr-seg { background: color-mix(in srgb, var(--good, #1FAE5B) 10%, transparent); border-radius: 10px; padding: 8px 10px; }
.sdr-lista { display: flex; flex-direction: column; gap: 10px; max-height: 46vh; overflow: auto; margin: 10px 0; }
.sdr-item { border: 1px solid var(--line); border-radius: 12px; padding: 8px 10px; }
.sdr-item.falhou { opacity: .6; }
.sdr-cab { display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap; margin-bottom: 6px; }
.sdr-cab .peq { flex: 1; min-width: 0; }
.sdr-item textarea { width: 100%; min-height: 84px; }
.sdr-ativar { background: linear-gradient(135deg, #FF3D00, #FF9100) !important; }
.dash-t { font-size: 14px; margin: 6px 0 10px; }
.dash-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin-bottom: 16px; }
.dash-tile { display: flex; flex-direction: column; gap: 6px; padding: 16px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); color: inherit; text-decoration: none; }
.dash-tile b { font-size: 30px; line-height: 1; font-variant-numeric: tabular-nums; }
.dash-tile span { font-size: 13px; color: var(--ink-2, inherit); }
.dash-tile.alerta { border-color: #e34948; }
.dash-tile.alerta b { color: #e34948; }
.dash-filtros { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 4px 0 14px; }
.dash-filtros .sel { max-width: 240px; }
.dash-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 14px; }
.dash-card { padding: 14px 16px; min-width: 0; }
.dash-card h3 { font-size: 14px; margin: 0 0 10px; }
.dash-larga { grid-column: 1 / -1; }
.dash-svg { width: 100%; height: auto; display: block; }
.dash-eixo { font-size: 10px; fill: var(--ink-3, #888); }
.dash-grade { stroke: var(--viz-grade); stroke-width: 1; }
.dash-base { stroke: var(--line); stroke-width: 1; }
.dash-bar:hover rect[fill]:not([fill="transparent"]) { opacity: .85; }
.dash-leg { display: flex; flex-wrap: wrap; gap: 14px; font-size: 12px; margin-bottom: 6px; }
.dash-leg i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
.dash-hb { display: grid; grid-template-columns: minmax(90px, 40%) 1fr auto; gap: 8px; align-items: center; font-size: 12px; margin: 6px 0; }
.dash-hb-n { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dash-hb-t { height: 10px; background: var(--viz-grade); border-radius: 5px; overflow: hidden; }
.dash-hb-t i { display: block; height: 100%; background: var(--series-1); border-radius: 5px; }
.dash-hb b { font-variant-numeric: tabular-nums; }
.dash-big { font-size: 26px; font-weight: 700; }
.dash-tab { margin-top: 8px; font-size: 12px; }
.dash-tab table { width: 100%; margin-top: 6px; }
.dash-ult { display: grid; grid-template-columns: 34px 1fr auto; gap: 10px; align-items: center; padding: 6px 0; color: inherit; text-decoration: none; border-bottom: 1px solid var(--line); }
.dash-ult .av { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; overflow: hidden; background: var(--viz-grade); font-size: 12px; }
.dash-ult small { display: block; color: var(--ink-3, #888); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dash-ult span:nth-child(2) { min-width: 0; }
.dash-ult em { font-style: normal; font-size: 11px; color: var(--ink-3, #888); }
@media (max-width: 760px) {
.sdr-cfg { grid-template-columns: 1fr; }
.sdr-item textarea { font-size: 16px; }
/* iOS não dá zoom ao digitar */
  /* Dashboard: cartões em 2 colunas */
  .dash-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.dash-tile { padding: 12px; }
.dash-tile b { font-size: 24px; }
.dash-tile span { font-size: 12px; }
.dash-grid { grid-template-columns: 1fr; }
.dash-hb { grid-template-columns: minmax(80px, 42%) 1fr auto; }
}
/* ===== 🏆 Corrida de vendas (Dashboard) ===== */
.corrida { margin-bottom: 18px; }
.corrida .dash-t small { font-weight: 500; margin-left: 6px; }
.cr-setores { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; margin-bottom: 12px; }
.cr-setor { border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; background: var(--surface); display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.cr-setor.batida { border-color: #1FAE5B; box-shadow: 0 0 0 1px #1FAE5B inset; }
.cr-setor.baixa { border-color: #E5484D; box-shadow: 0 0 0 1px #E5484D inset; }
.cr-setor-top { display: flex; justify-content: space-between; gap: 6px; align-items: center; }
.cr-setor-top b { font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cr-real { font-size: 22px; font-weight: 800; font-variant-numeric: tabular-nums; }
.cr-meta-bar { height: 7px; border-radius: 9px; background: var(--line); overflow: hidden; }
.cr-meta-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--red), var(--series-1)); border-radius: 9px; }
.cr-selo { font-size: 10.5px; font-weight: 700; padding: 2px 7px; border-radius: 999px; white-space: nowrap; }
.cr-selo.ok { background: #1FAE5B22; color: #15924C; }
.cr-selo.baixa { background: #E5484D22; color: #D13438; }
.cr-selo.ritmo { background: var(--line); color: inherit; opacity: .8; }
.cr-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 12px; }
@media (max-width: 900px) {
.cr-grid { grid-template-columns: minmax(0, 1fr); }
}
.cr-filtros { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0 10px; align-items: center; }
.cr-filtros .sel { min-width: 160px; }
.cr-lider { display: flex; gap: 12px; align-items: center; padding: 12px 14px; border-radius: 14px; margin-bottom: 10px; background: linear-gradient(120deg, #0b0b0b, #2a0a12); color: #fff; border: 1.5px solid #FFC400; }
.cr-lider small { display: block; opacity: .75; font-size: 11px; }
.cr-lider b { display: block; font-size: 20px; }
.cr-lider span { font-size: 12.5px; opacity: .9; }
.cr-coroa { font-size: 34px; filter: drop-shadow(0 0 6px rgba(255, 196, 0, .8)); animation: chama 1.2s ease-in-out infinite alternate; }
.cr-pistas { display: flex; flex-direction: column; gap: 6px; }
.cr-linha { display: grid; grid-template-columns: 34px minmax(70px, 120px) 1fr auto; gap: 8px; align-items: center; border: 1px solid transparent; background: none; color: inherit; padding: 5px 6px; border-radius: 10px; cursor: pointer; text-align: left; font: inherit; }
.cr-linha:hover, .cr-linha.on { background: var(--line); }
.cr-linha.lider { border-color: #FFC400; }
.cr-linha.baixa .cr-nome { color: #D13438; }
.cr-pos { font-weight: 800; text-align: center; }
.cr-nome { font-weight: 600; font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cr-pista { height: 16px; border-radius: 9px; background: color-mix(in srgb, var(--line) 60%, transparent); overflow: hidden; }
.cr-pista i { display: block; height: 100%; width: 0; border-radius: 9px; background: linear-gradient(90deg, var(--series-1), var(--red)); transition: width .9s cubic-bezier(.2, .8, .2, 1); }
.cr-pronto .cr-pista i { width: var(--w); }
.cr-linha.lider .cr-pista i { background: linear-gradient(90deg, #FF9100, #FFC400); }
.cr-v { font-variant-numeric: tabular-nums; font-size: 13px; }
.cr-cresc { display: grid; grid-template-columns: 1fr auto; gap: 2px 8px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.cr-cresc small { grid-column: 1 / -1; opacity: .7; font-size: 11.5px; }
.cr-cresc .sobe { color: #15924C; }
.cr-cresc .desce { color: #D13438; }
.cr-det { margin-top: 12px; border-top: 1px solid var(--line); padding-top: 10px; }
.cr-det h4 { margin: 0 0 8px; }
.cr-det h4 small { font-weight: 500; opacity: .7; }
.cr-tiles .dash-tile b { font-size: 15px; }
.cr-serie { display: grid; grid-template-columns: repeat(12, 1fr); gap: 4px; height: 90px; align-items: end; }
.cr-serie span { display: flex; flex-direction: column; justify-content: flex-end; align-items: center; height: 100%; gap: 3px; }
.cr-serie i { display: block; width: 100%; border-radius: 4px 4px 0 0; background: var(--series-1); }
.cr-serie small { font-size: 9.5px; opacity: .7; }
.cr-hist { margin-top: 12px; }
@media (max-width: 760px) {
.cr-linha { grid-template-columns: 28px minmax(60px, 90px) 1fr auto; gap: 6px; }
.cr-v { font-size: 12px; }
.cr-real { font-size: 19px; }
}
@media (prefers-reduced-motion: reduce) {
.cr-pista i { transition: none; }
.cr-coroa { animation: none; }
}
.pp { margin-bottom: 12px; }
.pp-barra { display: flex; height: 14px; border-radius: 9px; overflow: hidden; margin: 10px 0 14px; background: var(--line); gap: 2px; }
.pp-barra i { display: block; height: 100%; width: 0; background: var(--c); transition: width 1.1s cubic-bezier(.2, .8, .2, 1); }
.cr-pronto .pp-barra i { width: var(--w); }
.pp-lista { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 12px; }
.pp-item { display: flex; gap: 12px; align-items: center; min-width: 0; }
.pp-anel { --p: 0; flex: none; width: 74px; height: 74px; border-radius: 50%; display: grid; place-items: center;
  background: conic-gradient(var(--c) calc(var(--p) * 1%), color-mix(in srgb, var(--c) 14%, transparent) 0); transition: --p 1.3s cubic-bezier(.2, .8, .2, 1); }
.cr-pronto .pp-anel { --p: var(--alvo); }
.pp-anel span { width: 56px; height: 56px; border-radius: 50%; background: var(--surface); display: grid; place-items: center; }
.pp-anel b { font-size: 15px; font-variant-numeric: tabular-nums; color: var(--c); }
.pp-txt { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.pp-txt b { font-size: 14px; }
.pp-v { font-weight: 700; font-variant-numeric: tabular-nums; }
.pp-txt small { font-size: 11.5px; opacity: .8; line-height: 1.35; }
@media (prefers-reduced-motion: reduce) {
.pp-anel, .pp-barra i { transition: none; }
}
.cr-titulo { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.cr-titulo #cr-metas { margin-left: auto; }
.cr-v { display: flex; flex-direction: column; align-items: flex-end; line-height: 1.15; }
.cr-mt { font-size: 10.5px; font-weight: 500; opacity: .7; white-space: nowrap; }
/* ===== 🔮 Radar de vendas (painel da calma) ===== */
.radar { display: flex; flex-direction: column; gap: 14px; }
.rd-calma { padding: 16px 18px; border-radius: 16px; background: linear-gradient(120deg, color-mix(in srgb, #1FAE5B 14%, var(--surface)), color-mix(in srgb, var(--series-1) 12%, var(--surface))); border: 1px solid var(--line); font-size: 15px; line-height: 1.5; }
.rd-calma2 { margin-top: 6px; font-size: 13.5px; opacity: .9; }
.rd-aviso { padding: 10px 14px; border-radius: 12px; background: color-mix(in srgb, #3B82F6 12%, var(--surface)); border: 1px solid color-mix(in srgb, #3B82F6 35%, transparent); font-size: 13px; }
.rd-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 10px; }
.rd-card { border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; background: var(--surface); display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.rd-card.dest { border-color: var(--series-1); box-shadow: 0 0 0 1px var(--series-1) inset; }
.rd-nome { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; opacity: .75; }
.rd-prov { font-size: 23px; font-weight: 800; font-variant-numeric: tabular-nums; }
.rd-faixa { position: relative; height: 12px; border-radius: 9px; background: var(--line); margin: 8px 0 3px; overflow: hidden; }
.rd-banda { position: absolute; top: 0; bottom: 0; left: var(--a); right: calc(100% - var(--b)); background: color-mix(in srgb, var(--series-1) 28%, transparent); }
.rd-real { position: absolute; top: 3px; bottom: 3px; left: 0; width: 0; border-radius: 9px; background: #1FAE5B; transition: width 1.1s cubic-bezier(.2, .8, .2, 1); }
.rd-pronto .rd-real { width: var(--w); }
.rd-alvo { position: absolute; top: 0; bottom: 0; left: var(--x); width: 3px; margin-left: -1px; background: var(--red); border-radius: 2px; }
.rd-leg { display: flex; justify-content: space-between; font-size: 10.5px; opacity: .7; }
.rd-ja { font-size: 12.5px; margin-top: 3px; }
.rd-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; }
@media (max-width: 900px) {
.rd-grid { grid-template-columns: minmax(0, 1fr); }
}
.rd-canal { display: grid; grid-template-columns: minmax(110px, 170px) 1fr auto; grid-template-rows: auto auto; gap: 2px 10px; align-items: center; padding: 6px 0; }
.rd-canal small { grid-column: 3; font-size: 11px; opacity: .7; text-align: right; }
.rd-cn { font-weight: 600; font-size: 13px; }
.rd-trilho { position: relative; height: 14px; border-radius: 9px; background: var(--line); overflow: hidden; }
.rd-trilho i { position: absolute; left: 0; top: 0; bottom: 0; width: 0; border-radius: 9px; transition: width 1.1s cubic-bezier(.2, .8, .2, 1); }
.rd-fut { background: color-mix(in srgb, var(--c) 35%, transparent); }
.rd-jaC { background: var(--c); }
.rd-pronto .rd-trilho i { width: var(--w); }
.rd-ct { display: grid; grid-template-columns: 1fr auto auto; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); }
.rd-ct span small { display: block; font-size: 11.5px; opacity: .7; }
.rd-st { font-size: 11.5px; padding: 3px 8px; border-radius: 999px; background: var(--line); white-space: nowrap; }
.rd-st.ok { background: #1FAE5B22; color: #15924C; }
.rd-st.atr { background: #F5A52422; color: #B97A00; }
.rd-graf { width: 100%; height: auto; }
.rd-g-banda { fill: color-mix(in srgb, var(--red) 16%, transparent); }
.rd-g-real { fill: none; stroke: var(--series-1); stroke-width: 2.5; }
.rd-g-prov { fill: none; stroke: var(--red); stroke-width: 2.5; stroke-dasharray: 6 5; }
.rd-g-hoje { stroke: var(--line); stroke-width: 1.5; stroke-dasharray: 3 3; }
.rd-g-ponto { fill: var(--series-1); }
.rd-g-ponto.prev { fill: var(--red); }
.rd-cresc { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin-top: 10px; }
.rd-cresc .dash-tile b { font-size: 17px; }
.rd-dica { margin-top: 10px; padding: 10px 12px; border-radius: 12px; background: color-mix(in srgb, #F5A524 12%, var(--surface)); font-size: 13px; }
.rd-ac { display: grid; grid-template-columns: 70px 1fr 1fr auto; gap: 8px; padding: 6px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
@media (max-width: 760px) {
.rd-prov { font-size: 20px; }
.rd-canal { grid-template-columns: 1fr auto; }
.rd-canal .rd-trilho { grid-column: 1 / -1; grid-row: 2; }
.rd-canal small { grid-column: 2; grid-row: 1; display: none; }
}
@media (prefers-reduced-motion: reduce) {
.rd-real, .rd-trilho i { transition: none; }
}
.rd-graf { display: block; width: 100%; height: auto; max-height: 300px; margin: 0 auto; }
.rd-graf .dash-eixo { font-size: 10px; }
@media (max-width: 760px) {
.dash-tab table, .cr-hist table { display: block; max-width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; white-space: nowrap; }
.dash-ult small { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; text-overflow: clip; }
}/* cartões das ferramentas do robô */
.fr-lista { display: grid; gap: 10px; margin: 0 0 12px; }
.fr-card { padding: 0; }
.fr-card > summary { cursor: pointer; padding: 14px; list-style: none; display: flex; align-items: center; gap: 8px; min-height: 44px; }
.fr-card > summary::-webkit-details-marker { display: none; }
.fr-card > summary::after { content: '›'; margin-left: auto; transition: transform .2s; color: var(--ink-3); }
.fr-card[open] > summary::after { transform: rotate(90deg); }
.fr-corpo { padding: 0 14px 14px; display: grid; gap: 10px; }
.fr-corpo .rot { display: grid; gap: 4px; font-size: 13px; }
.fr-corpo .inp { font-size: 16px; }
.fr-corpo .btn { justify-self: start; min-height: 44px; }
tr.inativo { opacity: .55; }
/* celular: os cartões do robô nunca passam da margem; alvos de toque com 44 px */
.fr-lista { grid-template-columns: minmax(0, 1fr); width: 100%; max-width: 100%; min-width: 0; box-sizing: border-box; }
.fr-card, .fr-corpo, .fr-corpo > * { min-width: 0; max-width: 100%; box-sizing: border-box; }
.fr-corpo { grid-template-columns: minmax(0, 1fr); overflow-wrap: anywhere; }
.fr-corpo .inp, .fr-corpo textarea, .fr-corpo select { width: 100%; max-width: 100%; box-sizing: border-box; }
.fr-corpo .bot-aps { gap: 4px 16px; }
.fr-corpo .bot-aps .chk, .fr-corpo .interruptor { min-height: 44px; display: inline-flex; align-items: center; }
.fr-corpo .link-mini, .sdr-item .link-mini { min-height: 44px; min-width: 44px; padding: 0 8px; }
.fr-corpo .btn { min-height: 44px; }
/* o interruptor (input escondido) ocupa o rótulo inteiro: o toque vale na linha toda */
.fr-corpo .interruptor, .fr-lista ~ .card .interruptor { position: relative; min-height: 44px; }
.fr-corpo .interruptor input, .fr-lista ~ .card .interruptor input { inset: 0; width: 100%; height: 100%; margin: 0; }
.fr-corpo .bot-aps .chk { position: relative; padding-right: 6px; }
.fr-corpo .bot-aps .chk input { width: 22px; height: 22px; margin: 0; }
