/* Radar de Leads Hospitalares — identidade: petróleo profundo + areia, escala de temperatura própria */
:root {
  --petrol: #0d4a52;
  --petrol-2: #0a363c;
  --petrol-3: #135e68;
  --mint: #b9e3dc;
  --sand: #f5f1ea;
  --card: #fffdf9;
  --ink: #18272a;
  --muted: #5a6a6d;
  --line: #e4ddd1;
  --line-2: #efe9df;
  --coral: #d9643a;
  --t-ok: #23805c;
  --t-esq: #b8690a;
  --t-esf: #2a74b8;
  --t-frio: #3a3d96;
  --t-adiado: #6f7779;
  --bg-ok: #e3f3ec;
  --bg-esq: #fbefdc;
  --bg-esf: #e2eefa;
  --bg-frio: #e7e7f8;
  --danger: #b3261e;
  --bg-danger: #fbe9e7;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(16, 40, 44, .06), 0 4px 14px rgba(16, 40, 44, .06);
  --side: 252px;
  font-size: 15px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--sand); color: var(--ink);
  font: 400 15px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  overflow-x: hidden;
}
a { color: var(--petrol-3); }
h1, h2, h3, h4 { margin: 0; line-height: 1.2; letter-spacing: -.01em; }
h1 { font-size: 1.55rem; font-weight: 750; }
h2 { font-size: 1.15rem; font-weight: 700; }
h3 { font-size: 1rem; font-weight: 700; }
p { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
img, svg { max-width: 100%; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 3px solid #f0b44c; outline-offset: 2px; border-radius: 6px; }

/* ---------- estrutura ---------- */
.shell { min-height: 100vh; }
.side { display: none; }
.topbar {
  position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; background: var(--petrol); color: #fff; min-height: 56px;
}
.topbar .marca { display: flex; align-items: center; gap: 8px; font-weight: 750; font-size: 1.02rem; color: #fff; text-decoration: none; min-width: 0; }
.topbar .marca span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar .eu { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--mint); color: var(--petrol-2); display: grid; place-items: center; font-weight: 800; font-size: .85rem; flex: none; border: 0; cursor: pointer; }
main { padding: 16px 14px 96px; max-width: 1180px; margin: 0 auto; width: 100%; min-width: 0; }
.bottomnav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr;
  background: #fff; border-top: 1px solid var(--line); padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
  box-shadow: 0 -4px 16px rgba(16, 40, 44, .07);
}
.bottomnav a, .bottomnav button {
  display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 4px 2px; border: 0; background: none;
  color: var(--muted); text-decoration: none; font-size: .72rem; font-weight: 600; cursor: pointer; position: relative; min-width: 0;
}
.bottomnav svg { width: 24px; height: 24px; }
.bottomnav .ativo { color: var(--petrol); }
.bottomnav .ativo::before { content: ""; position: absolute; top: -6px; left: 28%; right: 28%; height: 3px; border-radius: 0 0 3px 3px; background: var(--coral); }
.bolinha { position: absolute; top: 0; right: calc(50% - 20px); min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--coral); color: #fff; font-size: .68rem; font-weight: 800; display: grid; place-items: center; }

@media (min-width: 960px) {
  /* a coluna da barra lateral é pintada no fundo do grid para não parecer cortada em páginas longas */
  .shell { display: grid; grid-template-columns: var(--side) minmax(0, 1fr); background: linear-gradient(90deg, var(--petrol-2) var(--side), var(--sand) var(--side)); }
  .side {
    display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; overflow-y: auto;
    background: var(--petrol-2); color: #dce9e7; padding: 20px 14px;
  }
  .topbar, .bottomnav { display: none; }
  main { padding: 28px 32px 48px; }
}
.side .marca { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; padding: 4px 8px 18px; }
.side .marca b { display: block; font-size: 1.02rem; line-height: 1.15; }
.side .marca small { display: block; color: var(--mint); font-size: .74rem; letter-spacing: .02em; }
.side nav { display: flex; flex-direction: column; gap: 2px; }
.side nav a {
  display: flex; align-items: center; gap: 11px; padding: 10px 12px; border-radius: 10px; color: #cfe0dd; text-decoration: none; font-weight: 550;
}
.side nav a svg { width: 20px; height: 20px; flex: none; opacity: .9; }
.side nav a:hover { background: rgba(255, 255, 255, .06); color: #fff; }
.side nav a.ativo { background: var(--petrol-3); color: #fff; box-shadow: inset 3px 0 0 var(--coral); }
.side nav a .num { margin-left: auto; background: var(--coral); color: #fff; border-radius: 10px; padding: 0 7px; font-size: .74rem; font-weight: 800; }
.side .rodape { margin-top: auto; padding: 14px 8px 0; border-top: 1px solid rgba(255, 255, 255, .1); display: flex; gap: 10px; align-items: center; }
.side .rodape .quem { min-width: 0; flex: 1; }
.side .rodape b { display: block; color: #fff; font-size: .9rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side .rodape small { color: var(--mint); font-size: .75rem; }
.side .sair { background: none; border: 1px solid rgba(255, 255, 255, .2); color: #dce9e7; border-radius: 8px; padding: 6px 10px; cursor: pointer; font-size: .8rem; }

/* ---------- cabeçalho de página ---------- */
.cab { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px 14px; margin-bottom: 16px; }
.cab .tit { flex: 1 1 260px; min-width: 0; }
.cab .sub { color: var(--muted); margin-top: 4px; }
.cab .acoes { display: flex; flex-wrap: wrap; gap: 8px; }
.sec { margin: 22px 0 10px; display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.sec h2 { flex: 1; }
.sec .dica { color: var(--muted); font-size: .85rem; }

/* ---------- botões e campos ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 42px; padding: 9px 16px; border-radius: 11px;
  border: 1px solid transparent; background: var(--petrol); color: #fff; font-weight: 650; cursor: pointer; text-decoration: none; line-height: 1.15;
  -webkit-tap-highlight-color: transparent; text-align: center;
}
.btn:hover { background: var(--petrol-3); }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn.sec2 { background: #fff; color: var(--petrol); border-color: #c9d9d7; }
.btn.sec2:hover { background: #f1f7f6; }
.btn.zap { background: #1f7a4d; }
.btn.zap:hover { background: #18663f; }
.btn.coral { background: var(--coral); }
.btn.coral:hover { background: #c4552d; }
.btn.perigo { background: #fff; color: var(--danger); border-color: #ecc4bf; }
.btn.perigo:hover { background: var(--bg-danger); }
.btn.peq { min-height: 36px; padding: 6px 12px; font-size: .88rem; border-radius: 9px; }
.btn.bloco { width: 100%; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }
.link { background: none; border: 0; color: var(--petrol-3); font-weight: 650; cursor: pointer; padding: 4px 0; text-decoration: underline; text-underline-offset: 3px; }
.campo { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.campo > span, .campo > label { font-size: .85rem; font-weight: 650; color: #354749; }
.campo small { color: var(--muted); font-size: .8rem; }
.inp, select.inp, textarea.inp {
  width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid #cfc7b9; border-radius: 10px; background: #fff; font-size: 16px; min-width: 0;
}
textarea.inp { min-height: 90px; resize: vertical; line-height: 1.45; }
.inp:focus { border-color: var(--petrol-3); outline: 3px solid rgba(19, 94, 104, .18); outline-offset: 0; }
.form { display: grid; gap: 14px; }
.form.duas { grid-template-columns: 1fr; }
@media (min-width: 700px) { .form.duas { grid-template-columns: 1fr 1fr; } .form.duas .largo { grid-column: 1 / -1; } }
.linha { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.linha > .inp { flex: 1 1 140px; }
.check { display: flex; align-items: flex-start; gap: 10px; padding: 8px 0; cursor: pointer; }
.check input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--petrol); flex: none; }
.erro-msg { background: var(--bg-danger); color: var(--danger); padding: 10px 12px; border-radius: 10px; font-weight: 600; }

/* data dd/mm/aaaa por cima do seletor nativo */
.dt-wrap { position: relative; display: block; min-width: 0; }
.dt-wrap .dt-lbl {
  display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 44px; padding: 10px 12px; border: 1px solid #cfc7b9; border-radius: 10px;
  background: #fff; font-size: 16px; pointer-events: none;
}
.dt-wrap .dt-lbl.vazio { color: #8a9193; }
.dt-wrap .dt-lbl svg { width: 18px; height: 18px; color: var(--muted); }
.dt-wrap input[type=date] { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; z-index: 1; border: 0; padding: 0; margin: 0; }
.dt-wrap input[type=date]::-webkit-calendar-picker-indicator { position: absolute; inset: 0; width: 100%; height: 100%; cursor: pointer; }
.dt-wrap:focus-within .dt-lbl { border-color: var(--petrol-3); outline: 3px solid rgba(19, 94, 104, .18); }

/* ---------- cartões ---------- */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; min-width: 0; }
.card + .card { margin-top: 12px; }
.card h3 { margin-bottom: 8px; }
.grade { display: grid; gap: 12px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 760px) { .grade.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .grade.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .grade.g3l { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); } }
.vazio-box { text-align: center; padding: 26px 16px; color: var(--muted); }
.vazio-box b { display: block; color: var(--ink); font-size: 1.05rem; margin-bottom: 4px; }

/* ---------- indicadores ---------- */
.tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (min-width: 760px) { .tiles { grid-template-columns: repeat(5, minmax(0, 1fr)); } .tiles.t4 { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.tile { text-decoration: none; color: var(--ink);
  background: var(--card); border: 1px solid var(--line); border-radius: 13px; padding: 12px 14px; text-align: left; cursor: pointer; display: flex; flex-direction: column; gap: 2px;
  box-shadow: var(--shadow); position: relative; overflow: hidden; min-width: 0;
}
.tile::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--c, var(--petrol)); }
.tile .n { font-size: 1.75rem; font-weight: 800; letter-spacing: -.02em; line-height: 1.1; }
.tile .r { font-size: .84rem; color: var(--muted); font-weight: 600; display: flex; align-items: center; gap: 5px; }
.tile.on { outline: 2px solid var(--c, var(--petrol)); outline-offset: -2px; }
.tile.estatico { cursor: default; }

/* temperatura (sempre com símbolo + texto, nunca só cor) */
.temp { display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px 3px 7px; border-radius: 20px; font-size: .78rem; font-weight: 750; white-space: nowrap; }
.temp i { font-style: normal; font-size: .8rem; }
.temp.em_dia { background: var(--bg-ok); color: var(--t-ok); }
.temp.atencao { background: var(--bg-esq); color: var(--t-esq); }
.temp.esfriando { background: var(--bg-esf); color: var(--t-esf); }
.temp.frio { background: var(--bg-frio); color: var(--t-frio); }
.temp.adiado { background: #eceeee; color: var(--t-adiado); }
.temp.fechado { background: #e5f1ef; color: var(--petrol); }
.temp.perdido { background: #f1e9e6; color: #8a4b3a; }
.chip { display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 20px; background: #eee8dd; color: #4a5759; font-size: .78rem; font-weight: 650; white-space: nowrap; }
.chip.etapa { background: #e2efed; color: var(--petrol); }
.chip.voce { background: #fde6dc; color: #9a3d1c; }
.chip.vencida { background: var(--bg-danger); color: var(--danger); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.filtros { display: flex; gap: 6px; flex-wrap: wrap; margin: 4px 0 12px; }
.filtro { border: 1px solid #d5cdbf; background: #fff; border-radius: 20px; padding: 7px 13px; font-size: .86rem; font-weight: 650; cursor: pointer; color: #3c4b4d; min-height: 36px; }
.filtro.on { background: var(--petrol); border-color: var(--petrol); color: #fff; }
.filtro .q { opacity: .75; margin-left: 3px; }

/* alerta do topo */
.alerta-hoje { background: linear-gradient(135deg, #0e4f58, #0a363c); color: #fff; border-radius: 18px; padding: 16px; margin-bottom: 14px; position: relative; overflow: hidden; }
.alerta-hoje::after { content: ""; position: absolute; right: -60px; top: -60px; width: 200px; height: 200px; border-radius: 50%; border: 2px solid rgba(185, 227, 220, .18); box-shadow: 0 0 0 30px rgba(185, 227, 220, .05), 0 0 0 60px rgba(185, 227, 220, .04); pointer-events: none; }
.alerta-hoje h2 { display: flex; align-items: center; gap: 8px; font-size: 1.12rem; }
.alerta-hoje .sub { color: #bfe0da; font-size: .88rem; margin-top: 3px; }
.alerta-hoje .lista-hoje { display: grid; gap: 8px; margin-top: 12px; position: relative; z-index: 1; }
@media (min-width: 760px) { .alerta-hoje .lista-hoje { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); } }
.hoje-item { background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .14); border-radius: 12px; padding: 10px 12px; color: #fff; text-decoration: none; display: flex; flex-direction: column; gap: 4px; }
.hoje-item:hover { background: rgba(255, 255, 255, .13); }
.hoje-item b { font-size: .98rem; }
.hoje-item small { color: #cfe5e1; }
.hoje-item .temp { align-self: flex-start; }

/* cartão de lead */
.leads { display: grid; gap: 10px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 1100px) { .leads.duas { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.lead { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px; display: flex; flex-direction: column; gap: 8px; min-width: 0; border-left: 4px solid var(--c, var(--line)); }
.lead.esfriando { --c: var(--t-esf); } .lead.frio { --c: var(--t-frio); } .lead.atencao { --c: var(--t-esq); } .lead.em_dia { --c: var(--t-ok); }
.lead .topo { display: flex; gap: 10px; align-items: flex-start; }
.lead .nome { flex: 1; min-width: 0; }
.lead .nome a { color: var(--ink); text-decoration: none; font-weight: 750; font-size: 1.02rem; }
.lead .nome small { display: block; color: var(--muted); font-size: .84rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lead .meta { display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: center; font-size: .85rem; color: var(--muted); }
.lead .meta b { color: var(--ink); }
.lead .ultima { font-size: .88rem; background: #f6f2ea; border-radius: 10px; padding: 8px 10px; color: #3b4a4c; overflow-wrap: anywhere; }
.lead .ultima em { font-style: normal; font-weight: 700; color: var(--ink); }
.lead .botoes { display: flex; flex-wrap: wrap; gap: 8px; }
.lead .botoes .btn { flex: 1 1 140px; }

/* próximo passo */
.sug { border: 1px solid #c7e0db; background: #f2f9f7; border-radius: 13px; padding: 12px; display: flex; flex-direction: column; gap: 10px; }
.sug .acao { display: flex; align-items: center; gap: 8px; font-weight: 750; color: var(--petrol); }
.sug .acao svg { width: 20px; height: 20px; flex: none; }
.sug .msg { background: #fff; border: 1px dashed #b5d3cd; border-radius: 10px; padding: 10px 12px; white-space: pre-wrap; font-size: .95rem; overflow-wrap: anywhere; }
.sug .bts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
@media (min-width: 560px) { .sug .bts { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.sug .bts .btn { min-height: 44px; padding: 8px 10px; font-size: .9rem; }

/* ---------- funil ---------- */
.etapas-mob { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.kanban { display: none; }
@media (min-width: 960px) {
  .etapas-mob { display: none; }
  .lista-mob { display: none; }
  .kanban { display: grid; grid-auto-flow: column; grid-auto-columns: 238px; gap: 12px; overflow-x: auto; padding-bottom: 12px; align-items: start; }
}
.col { background: #ece6db; border-radius: 14px; padding: 10px; min-height: 120px; }
.col.alvo { background: #dcece8; outline: 2px dashed var(--petrol-3); }
.col .colcab { display: flex; justify-content: space-between; align-items: center; padding: 2px 4px 10px; font-weight: 750; font-size: .92rem; }
.col .colcab .q { background: #fff; border-radius: 12px; padding: 1px 9px; font-size: .8rem; }
.col .cards { display: flex; flex-direction: column; gap: 8px; }
.mini { background: #fff; border-radius: 11px; padding: 10px; border: 1px solid var(--line); box-shadow: 0 1px 2px rgba(0, 0, 0, .04); cursor: grab; display: flex; flex-direction: column; gap: 6px; border-left: 4px solid var(--c, var(--line)); }
.mini.esfriando { --c: var(--t-esf); } .mini.frio { --c: var(--t-frio); } .mini.atencao { --c: var(--t-esq); } .mini.em_dia { --c: var(--t-ok); }
.mini a { color: var(--ink); font-weight: 700; text-decoration: none; font-size: .92rem; }
.mini small { color: var(--muted); font-size: .8rem; line-height: 1.3; }
.mini select { font-size: .82rem; min-height: 34px; padding: 4px 8px; }
.mini.arrastando { opacity: .45; }

/* ---------- ficha ---------- */
.ficha-cab { display: flex; flex-direction: column; gap: 10px; }
.ficha-cab .linha1 { display: flex; gap: 12px; align-items: flex-start; }
.ficha-cab .ini { width: 48px; height: 48px; border-radius: 14px; background: var(--petrol); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 1.05rem; flex: none; }
.ficha-cab h1 { font-size: 1.35rem; overflow-wrap: anywhere; }
.ficha-cab .quem { color: var(--muted); font-size: .92rem; overflow-wrap: anywhere; }
.situacao { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
@media (min-width: 760px) { .situacao { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.situacao div { background: #f6f2ea; border-radius: 11px; padding: 8px 10px; min-width: 0; }
.situacao small { display: block; color: var(--muted); font-size: .76rem; font-weight: 650; text-transform: uppercase; letter-spacing: .04em; }
.situacao b { font-size: .95rem; overflow-wrap: anywhere; }
.abas { display: flex; gap: 4px; background: #ebe4d8; padding: 4px; border-radius: 12px; margin: 16px 0 12px; overflow-x: auto; scrollbar-width: none; }
.abas::-webkit-scrollbar { display: none; }
.abas button { flex: 1 0 auto; border: 0; background: none; padding: 9px 12px; border-radius: 9px; font-weight: 700; color: #4b5a5c; cursor: pointer; font-size: .88rem; white-space: nowrap; }
.abas button.on { background: #fff; color: var(--petrol); box-shadow: 0 1px 3px rgba(0, 0, 0, .08); }
.itens { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.itens li { display: flex; gap: 10px; align-items: flex-start; padding: 8px 0; border-bottom: 1px solid var(--line-2); min-width: 0; }
.itens li:last-child { border-bottom: 0; }
.itens .quando { color: var(--muted); font-size: .8rem; white-space: nowrap; }
.itens .txt { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.ponto { width: 10px; height: 10px; border-radius: 50%; background: var(--petrol-3); margin-top: 6px; flex: none; }
.ponto.pl { background: #b8690a; } .ponto.pn { background: var(--petrol-3); } .ponto.alerta { background: var(--coral); }
.evid { font-size: .86rem; color: var(--muted); background: #f6f2ea; border-radius: 10px; padding: 8px 10px; }

/* conversa */
.conversa { display: flex; flex-direction: column; gap: 6px; background: #efe9de; border-radius: 14px; padding: 12px; max-height: 70vh; overflow-y: auto; }
.dia-sep { align-self: center; background: #fff; color: var(--muted); font-size: .76rem; font-weight: 700; padding: 3px 10px; border-radius: 10px; margin: 6px 0; }
.bolha { max-width: 86%; padding: 7px 10px 5px; border-radius: 12px; background: #fff; box-shadow: 0 1px 1px rgba(0, 0, 0, .06); overflow-wrap: anywhere; font-size: .93rem; }
.bolha.nos { align-self: flex-end; background: #dff1ea; border-top-right-radius: 4px; }
.bolha.lead { align-self: flex-start; border-top-left-radius: 4px; }
.bolha.sistema { align-self: center; background: #fbf3d5; font-size: .8rem; color: #6b5c1e; }
.bolha .aut { font-size: .74rem; font-weight: 750; color: #9a5a0c; }
.bolha.nos .aut { color: var(--petrol-3); }
.bolha .hr { display: block; text-align: right; font-size: .7rem; color: #7b8587; margin-top: 1px; }

/* tarefas */
.tarefa { display: flex; gap: 10px; align-items: flex-start; padding: 12px; background: var(--card); border: 1px solid var(--line); border-radius: 12px; min-width: 0; }
.tarefa.vencida { border-color: #ecc4bf; background: #fff8f6; box-shadow: inset 4px 0 0 var(--danger); }
.tarefa.feita .tt { text-decoration: line-through; color: var(--muted); }
.tarefa input[type=checkbox] { width: 24px; height: 24px; accent-color: var(--petrol); margin: 1px 0 0; flex: none; cursor: pointer; }
.tarefa .corpo { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.tarefa .tt { font-weight: 650; overflow-wrap: anywhere; }
.tarefa .info { display: flex; flex-wrap: wrap; gap: 6px 10px; font-size: .82rem; color: var(--muted); align-items: center; }
.grupo-t { display: flex; flex-direction: column; gap: 8px; margin-bottom: 18px; }
.grupo-t h3 { font-size: .86rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin: 4px 0 2px; }
.grupo-t h3.verm { color: var(--danger); }

/* gráficos (barras simples; cores da paleta validada) */
.barras { display: flex; flex-direction: column; gap: 9px; }
.barra { display: grid; grid-template-columns: minmax(90px, 34%) minmax(0, 1fr) auto; gap: 10px; align-items: center; font-size: .88rem; position: relative; }
.barra .rot { color: #34474a; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.barra .trilho { display: block; height: 14px; background: #f0ebe2; border-radius: 4px; overflow: hidden; }
.barra .ench { display: block; height: 100%; border-radius: 0 4px 4px 0; background: var(--petrol-3); min-width: 2px; }
.barra .val { font-weight: 750; font-variant-numeric: tabular-nums; min-width: 2ch; text-align: right; }
.colunas { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 6px; align-items: end; height: 170px; padding-top: 18px; border-bottom: 1px solid #d9d1c3; position: relative; }
.colunas .sem { display: flex; gap: 2px; align-items: flex-end; justify-content: center; height: 100%; position: relative; cursor: default; }
.colunas .sem .c { width: 30%; max-width: 14px; border-radius: 4px 4px 0 0; min-height: 0; }
.colunas .sem:hover .c, .colunas .sem:focus .c { filter: brightness(.9); }
.eixo { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 6px; font-size: .72rem; color: var(--muted); text-align: center; margin-top: 5px; }
.legenda { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: .82rem; color: #3c4b4d; margin-top: 10px; }
.legenda span { display: inline-flex; align-items: center; gap: 6px; }
.legenda i { width: 12px; height: 12px; border-radius: 3px; display: inline-block; }
.s1 { background: #2a78d6; } .s2 { background: #eb6834; } .s3 { background: #1baf7a; }
.dica-g { position: absolute; z-index: 5; bottom: calc(100% + 4px); left: 50%; transform: translateX(-50%); background: var(--ink); color: #fff; font-size: .76rem; padding: 6px 8px; border-radius: 8px; white-space: nowrap; display: none; pointer-events: none; }
.colunas .sem:hover .dica-g, .colunas .sem:focus .dica-g { display: block; }
.colunas .sem:first-child .dica-g { left: 0; transform: none; }
.colunas .sem:last-child .dica-g { left: auto; right: 0; transform: none; }
table.tab { width: 100%; border-collapse: collapse; font-size: .88rem; }
table.tab th, table.tab td { text-align: left; padding: 8px 6px; border-bottom: 1px solid var(--line-2); vertical-align: top; }
table.tab th { font-size: .76rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
table.tab td.n { text-align: right; font-variant-numeric: tabular-nums; }
.rolavel { overflow-x: auto; max-width: 100%; }

/* regras */
.etapa-regra { border: 1px solid var(--line); border-radius: 13px; padding: 12px; background: #fff; display: flex; flex-direction: column; gap: 10px; }
.etapa-regra .prazos { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; }
@media (min-width: 560px) and (max-width: 759px), (min-width: 1200px) { .etapa-regra .prazos { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.etapa-regra .prazo { display: grid; grid-template-columns: 120px minmax(0, 1fr); align-items: center; }
@media (min-width: 560px) and (max-width: 759px), (min-width: 1200px) { .etapa-regra .prazo { display: flex; } }
.prazo { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.prazo span { font-size: .78rem; font-weight: 750; display: flex; align-items: center; gap: 4px; }
.prazo .duo { display: flex; gap: 4px; min-width: 0; }
.prazo .duo input { flex: 1 1 50px; min-width: 0; padding: 8px; }
.prazo .duo select { flex: 0 0 84px; padding: 8px 4px; min-width: 0; }
.modelo { border: 1px solid var(--line); border-radius: 12px; padding: 12px; background: #fff; display: flex; flex-direction: column; gap: 6px; }
.modelo .msg { color: #3c4b4d; font-size: .9rem; white-space: pre-wrap; overflow-wrap: anywhere; }
.modelo.inativo { opacity: .6; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag-btn { border: 1px dashed #b5c9c6; background: #f4faf9; color: var(--petrol); border-radius: 8px; padding: 4px 8px; font-size: .8rem; cursor: pointer; font-family: ui-monospace, Menlo, monospace; }
.toggle { display: flex; align-items: center; gap: 10px; cursor: pointer; }
.toggle input { width: 22px; height: 22px; accent-color: var(--petrol); }

/* importação */
.passos { counter-reset: p; display: flex; flex-direction: column; gap: 8px; margin: 0; padding: 0; list-style: none; }
.passos li { counter-increment: p; position: relative; padding-left: 34px; min-height: 24px; }
.passos li::before { content: counter(p); position: absolute; left: 0; top: 0; width: 24px; height: 24px; border-radius: 50%; background: var(--petrol); color: #fff; font-weight: 800; font-size: .8rem; display: grid; place-items: center; flex: none; }
.soltar { border: 2px dashed #b9cfcc; border-radius: 16px; background: #f4faf9; padding: 22px 14px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 10px; transition: background .15s; }
.soltar.sobre { background: #dff0ec; border-color: var(--petrol-3); }
.soltar > svg { width: 42px; height: 42px; color: var(--petrol-3); }
details.como { border: 1px solid var(--line); border-radius: 12px; background: #fff; padding: 0 12px; }
details.como + details.como { margin-top: 8px; }
details.como summary { cursor: pointer; padding: 12px 0; font-weight: 700; }
details.como .passos { padding-bottom: 12px; }
.autores { display: flex; flex-direction: column; gap: 4px; }
.aviso { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border-radius: 12px; background: #fff7e6; border: 1px solid #f1d9a8; color: #6b4a0b; font-size: .9rem; }
.aviso.ok { background: #e9f6f1; border-color: #bfe3d5; color: #1d5a42; }
.aviso svg { width: 20px; height: 20px; flex: none; margin-top: 1px; }

/* ---------- modal e aviso rápido ---------- */
.fundo { position: fixed; inset: 0; z-index: 100; background: rgba(10, 30, 33, .5); display: flex; align-items: flex-end; justify-content: center; padding: 0; }
.modal { background: var(--card); width: 100%; max-width: 560px; max-height: 92vh; overflow-y: auto; border-radius: 18px 18px 0 0; padding: 18px 16px calc(18px + env(safe-area-inset-bottom)); box-shadow: 0 -10px 40px rgba(0, 0, 0, .2); }
@media (min-width: 700px) { .fundo { align-items: center; padding: 20px; } .modal { border-radius: 18px; } }
.modal .mcab { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.modal .mcab h2 { flex: 1; }
.modal .fechar { border: 0; background: #eee8dd; width: 36px; height: 36px; border-radius: 50%; cursor: pointer; font-size: 1.2rem; line-height: 1; }
.modal .mrod { display: flex; gap: 8px; justify-content: flex-end; margin-top: 16px; flex-wrap: wrap; }
.modal .mrod .btn { flex: 1 1 140px; }
.toast { position: fixed; left: 50%; bottom: 92px; transform: translateX(-50%); z-index: 200; background: var(--ink); color: #fff; padding: 11px 16px; border-radius: 12px; font-weight: 600; box-shadow: 0 6px 24px rgba(0, 0, 0, .25); max-width: calc(100vw - 28px); text-align: center; }
@media (min-width: 960px) { .toast { bottom: 28px; left: calc(50% + var(--side) / 2); } }
.menu-mais { display: grid; gap: 6px; }
.menu-mais a, .menu-mais button { display: flex; align-items: center; gap: 12px; padding: 13px 12px; border-radius: 12px; background: #fff; border: 1px solid var(--line); color: var(--ink); text-decoration: none; font-weight: 650; cursor: pointer; text-align: left; width: 100%; }
.menu-mais svg { width: 22px; height: 22px; color: var(--petrol); }
.carregando { padding: 40px 0; text-align: center; color: var(--muted); }
.carregando::before { content: ""; display: block; width: 34px; height: 34px; margin: 0 auto 10px; border-radius: 50%; border: 3px solid #d8e6e3; border-top-color: var(--petrol-3); animation: gira .8s linear infinite; }
@keyframes gira { to { transform: rotate(360deg); } }
.permissoes td, .permissoes th { text-align: center; }
.permissoes td:first-child, .permissoes th:first-child { text-align: left; }
.sim { color: var(--t-ok); font-weight: 800; } .nao { color: #a0a6a7; }
.mt { margin-top: 12px; } .mt2 { margin-top: 20px; } .mb { margin-bottom: 12px; }
.muted { color: var(--muted); } .peq { font-size: .85rem; }
.sep { height: 1px; background: var(--line); margin: 14px 0; }
.direita { margin-left: auto; }
