/* =====================================================================
   Prumada — Estilos. Cores-padrão da marca Prumada (Grafite #13202B, Amarelo Sinal #FFB81C);
   cada empresa substitui --laranja (cor principal) e --verde (cor do menu) pelas suas
   em Configurações › Identidade visual. --on-laranja = cor do texto sobre a cor principal.
   Paleta: Laranja #FF5824 / #FF6D33 / #FF8B4A · Verde #0D2B18 · Azul gelo #BFE6EF
           Cinzas #F7F7F7 / #D3D3D3 · Preto · Tipografia: Noto Sans
   ===================================================================== */
:root {
  --laranja: #FFB81C;
  --laranja-2: #FFC23E;
  --laranja-3: #FFCD5F;
  --laranja-ink: #8A5D00;          /* cor principal escurecida para texto (contraste AA) */
  --on-laranja: #13202B;           /* texto sobre a cor principal */
  --verde: #13202B;
  --verde-2: #1F2D38;
  --verde-3: #33414C;
  --gelo: #C9D3DA;
  --gelo-2: #E8EEF2;
  --cinza-1: #F7F7F7;
  --cinza-2: #D3D3D3;
  --cinza-3: #8A8A8A;
  --ink: #111111;
  --ink-2: #4A4A47;
  --ink-3: #75746F;
  --surface: #FFFFFF;
  --bg: #F7F7F7;
  --line: #E4E4E2;
  --good: #0E8A3A;
  --bad: #C8322F;
  --warn: #B87500;
  --info: #2A78D6;
  --radius: 12px;
  --radius-s: 8px;
  --shadow: 0 1px 2px rgba(13, 43, 24, .06), 0 4px 16px rgba(13, 43, 24, .05);
  --sidebar: 248px;
  --font: 'Noto Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body { font-family: var(--font); background: var(--bg); color: var(--ink); font-size: 14px; line-height: 1.45; -webkit-font-smoothing: antialiased; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--laranja-ink); }
h1, h2, h3, h4 { margin: 0; font-weight: 700; letter-spacing: -.01em; }
.hidden { display: none !important; }
.muted { color: var(--ink-3); }
.nowrap { white-space: nowrap; }
.right { text-align: right; }
.num { font-variant-numeric: tabular-nums; }

/* ------------------------------ Login ------------------------------ */
.login { min-height: 100vh; display: grid; grid-template-columns: 1.1fr 1fr; }
.login-art { background: var(--verde); color: #fff; padding: 48px; display: flex; flex-direction: column; justify-content: space-between; position: relative; overflow: hidden; }
.login-art img { width: 200px; }
.login-art h1 { font-size: 40px; line-height: 1.1; font-weight: 600; max-width: 440px; }
.login-art h1 b { color: var(--laranja); font-weight: 800; }
.login-art .tag { color: var(--gelo); font-size: 13px; letter-spacing: .08em; text-transform: uppercase; }
.login-art .shape { position: absolute; right: -80px; bottom: -60px; width: 380px; opacity: .14; }
.login-form { display: flex; align-items: center; justify-content: center; padding: 32px 20px; background: #fff; }
.login-form form { width: 100%; max-width: 360px; display: grid; gap: 14px; }
.login-form h2 { font-size: 24px; }

/* ------------------------------ Shell ------------------------------ */
.app { display: grid; grid-template-columns: var(--sidebar) minmax(0, 1fr); min-height: 100vh; background: linear-gradient(to right, var(--verde) var(--sidebar), transparent 0); }
.sidebar { background: var(--verde); color: #fff; position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; padding: 20px 14px; }
.sidebar .brand { padding: 4px 8px 22px; }
.sidebar .brand img { width: 132px; display: block; }
.sidebar .brand small { display: block; color: var(--gelo); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; margin-top: 8px; }
.nav { display: grid; gap: 2px; }
.nav a { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: var(--radius-s); color: #DCE9E1; text-decoration: none; font-weight: 500; }
.nav a svg { width: 20px; height: 20px; flex: none; }
.nav a:hover { background: var(--verde-2); color: #fff; }
.nav a.active { background: var(--laranja); color: var(--on-laranja); }
.nav .sep { height: 1px; background: rgba(255, 255, 255, .1); margin: 10px 6px; }
.sidebar .me { margin-top: auto; padding: 12px; border-radius: var(--radius-s); background: var(--verde-2); font-size: 13px; }
.sidebar .me b { display: block; }
.sidebar .me button { margin-top: 8px; background: none; border: 1px solid rgba(255, 255, 255, .25); color: #fff; border-radius: 6px; padding: 4px 10px; cursor: pointer; font-size: 12px; }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar { display: flex; align-items: center; gap: 12px; padding: 18px 28px 6px; }
.topbar h1 { font-size: 22px; }
.topbar .sub { color: var(--ink-3); font-size: 13px; }
.topbar .actions { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }
.content { padding: 12px 28px 40px; display: grid; gap: 18px; grid-template-columns: minmax(0, 1fr); }
.mobilebar, .bottomnav { display: none; }
.demo-banner { background: var(--gelo); color: var(--verde); padding: 8px 28px; font-size: 13px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.demo-banner b { font-weight: 700; }

/* ------------------------------ Botões / Form ------------------------------ */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; border: 1px solid var(--cinza-2); background: #fff; color: var(--ink); border-radius: var(--radius-s); padding: 8px 14px; font-weight: 600; cursor: pointer; min-height: 38px; text-decoration: none; white-space: nowrap; }
.btn:hover { border-color: var(--ink-3); }
.btn svg { width: 18px; height: 18px; }
.btn.primary { background: var(--laranja); border-color: var(--laranja); color: var(--on-laranja); }
.btn.primary:hover { background: var(--laranja-2); }
.btn.dark { background: var(--verde); border-color: var(--verde); color: #fff; }
.btn.ghost { border-color: transparent; background: transparent; }
.btn.danger { color: var(--bad); border-color: #F0C4C3; }
.btn.sm { min-height: 30px; padding: 4px 10px; font-size: 13px; }
.btn:disabled { opacity: .5; cursor: default; }
label.f { display: grid; gap: 4px; font-size: 12px; font-weight: 600; color: var(--ink-2); }
label.f span.hint { font-weight: 400; color: var(--ink-3); }
.in, select.in, textarea.in { width: 100%; border: 1px solid var(--cinza-2); border-radius: var(--radius-s); padding: 9px 11px; background: #fff; min-height: 40px; font-size: 14px; }
textarea.in { min-height: 80px; resize: vertical; }
.in:focus { outline: 2px solid var(--laranja-3); outline-offset: 0; border-color: var(--laranja); }
.in[readonly] { background: var(--cinza-1); }
.grid-form { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.grid-form .s2 { grid-column: span 2; } .grid-form .s3 { grid-column: span 3; } .grid-form .s4 { grid-column: span 4; }
.err { color: var(--bad); font-size: 13px; min-height: 18px; }

/* ------------------------------ Filtros ------------------------------ */
.filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 12px; }
.filters select, .filters input { border: 1px solid var(--cinza-2); border-radius: 999px; padding: 6px 12px; background: #fff; min-height: 34px; font-size: 13px; max-width: 200px; }
.filters .chk { display: flex; gap: 6px; align-items: center; font-size: 13px; color: var(--ink-2); }
.ftoggle { display: none !important; }
.filters .count { margin-left: auto; color: var(--ink-3); font-size: 12px; }

/* ------------------------------ Cards / KPIs ------------------------------ */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px 18px; min-width: 0; }
.card h3 { font-size: 15px; margin-bottom: 2px; }
.card .cap { color: var(--ink-3); font-size: 12px; margin-bottom: 12px; }
.card-head { display: flex; gap: 8px; align-items: flex-start; justify-content: space-between; }
.kpis { display: grid; grid-template-columns: repeat(auto-fill, minmax(178px, 1fr)); gap: 12px; }
.kpi { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; position: relative; overflow: hidden; }
.kpi::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--cinza-2); }
.kpi.hl::before { background: var(--laranja); }
.kpi.gr::before { background: var(--verde); }
.kpi.bl::before { background: var(--gelo); }
.kpi .lb { font-size: 12px; color: var(--ink-2); font-weight: 600; display: flex; gap: 4px; align-items: center; }
.kpi .vl { font-size: 24px; font-weight: 800; letter-spacing: -.02em; margin-top: 4px; font-variant-numeric: tabular-nums; }
.kpi .ft { font-size: 12px; color: var(--ink-3); margin-top: 2px; }
.kpi .ft .up { color: var(--good); font-weight: 600; } .kpi .ft .dn { color: var(--bad); font-weight: 600; }
.help { display: inline-flex; width: 15px; height: 15px; border-radius: 50%; background: var(--cinza-1); border: 1px solid var(--cinza-2); color: var(--ink-3); font-size: 10px; align-items: center; justify-content: center; cursor: help; font-weight: 700; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.span-2 { grid-column: span 2; }
.chart-box { position: relative; height: 280px; }
.chart-box.tall { height: 360px; }
.chart-box.short { height: 220px; }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--ink-2); margin-bottom: 8px; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }

/* barra de progresso / meter */
.meter { height: 8px; background: var(--cinza-1); border-radius: 999px; overflow: hidden; }
.meter > i { display: block; height: 100%; background: var(--laranja); border-radius: 999px; }
.meter.g > i { background: var(--verde-3); }

/* ------------------------------ Tabelas ------------------------------ */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table.t { width: 100%; border-collapse: collapse; font-size: 13px; }
table.t th { text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-3); font-weight: 700; padding: 8px 10px; border-bottom: 1px solid var(--line); background: #fff; position: sticky; top: 0; white-space: nowrap; cursor: default; }
table.t th.sort { cursor: pointer; } table.t th.sort:hover { color: var(--ink); }
table.t td { padding: 9px 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.t tbody tr:hover { background: color-mix(in srgb, var(--laranja) 6%, #fff); }
table.t tr.click { cursor: pointer; }
table.t td.num, table.t th.num { text-align: right; font-variant-numeric: tabular-nums; }
table.t tfoot td { font-weight: 700; border-top: 2px solid var(--line); }

/* status pill */
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 2px 10px 2px 8px; border-radius: 999px; font-size: 12px; font-weight: 600; white-space: nowrap; border: 1px solid transparent; }
.pill::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.pill.g-elab { background: #F1F1EF; color: #4A4A47; }
.pill.g-aberto { background: var(--gelo-2); color: #145A6E; }
.pill.g-ganho { background: #E3F4E8; color: #0B6B2E; }
.pill.g-perdido { background: #FBE7E6; color: #A42925; }
.pill.g-cancel { background: #FFF1E0; color: #8A5300; }
.pill.g-decl { background: #EEE; color: #555; }
.tagc { display: inline-block; padding: 1px 8px; border-radius: 6px; background: var(--cinza-1); border: 1px solid var(--line); font-size: 11px; color: var(--ink-2); }

/* ranking */
.podium { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.pod { border-radius: var(--radius); padding: 16px; background: #fff; border: 1px solid var(--line); text-align: center; position: relative; }
.pod .pos { width: 34px; height: 34px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-weight: 800; color: #fff; background: var(--cinza-3); }
.pod.p1 { border-color: var(--laranja); box-shadow: 0 0 0 2px color-mix(in srgb, var(--laranja) 15%, transparent); } .pod.p1 .pos { background: var(--laranja); color: var(--on-laranja); }
.pod.p2 .pos { background: var(--verde); } .pod.p3 .pos { background: var(--laranja-3); }
.pod .nm { font-weight: 700; font-size: 16px; margin-top: 8px; }
.pod .sc { font-size: 28px; font-weight: 800; color: var(--verde); }
.avatar { width: 30px; height: 30px; border-radius: 50%; background: var(--gelo); color: var(--verde); display: inline-flex; align-items: center; justify-content: center; font-weight: 700; font-size: 12px; flex: none; }
.who { display: flex; align-items: center; gap: 8px; }

/* tabs */
.tabs { display: flex; gap: 4px; background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 4px; width: max-content; max-width: 100%; overflow-x: auto; }
.tabs button { border: 0; background: none; padding: 7px 16px; border-radius: 999px; font-weight: 600; color: var(--ink-2); cursor: pointer; white-space: nowrap; }
.tabs button.on { background: var(--verde); color: #fff; }

/* kanban */
.kanban { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(270px, 1fr); gap: 12px; overflow-x: auto; padding-bottom: 8px; align-items: start; }
.col { background: #EFEFED; border-radius: var(--radius); padding: 10px; min-height: 200px; }
.col.over { outline: 2px dashed var(--laranja); }
.col h4 { font-size: 13px; display: flex; justify-content: space-between; margin: 2px 4px 10px; }
.col h4 small { color: var(--ink-3); font-weight: 600; }
.kcard { background: #fff; border-radius: var(--radius-s); padding: 10px 12px; margin-bottom: 8px; border: 1px solid var(--line); cursor: pointer; border-left: 3px solid var(--cinza-2); }
.kcard:hover { border-color: var(--laranja-3); }
.kcard .c { font-size: 11px; color: var(--ink-3); font-weight: 600; }
.kcard .o { font-weight: 600; margin: 2px 0 6px; font-size: 13px; }
.kcard .v { font-weight: 800; font-variant-numeric: tabular-nums; }
.kcard .m { display: flex; justify-content: space-between; align-items: center; font-size: 12px; color: var(--ink-3); gap: 6px; }
.kcard.late { border-left-color: var(--bad); }

/* lista mobile de orçamentos */
.olist { display: none; }
.ocard { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; display: grid; gap: 6px; }
.ocard .top { display: flex; justify-content: space-between; gap: 8px; font-size: 12px; color: var(--ink-3); font-weight: 600; }
.ocard .ob { font-weight: 700; }
.ocard .bt { display: flex; justify-content: space-between; align-items: center; gap: 8px; }

/* ------------------------------ Modal ------------------------------ */
.modal-bg { position: fixed; inset: 0; background: rgba(13, 43, 24, .45); display: flex; align-items: center; justify-content: center; z-index: 50; padding: 32px 16px; }
.modal { background: #fff; border-radius: 16px; width: 100%; max-width: 980px; box-shadow: 0 20px 60px rgba(0, 0, 0, .25); display: flex; flex-direction: column; max-height: calc(100vh - 64px); max-height: calc(100dvh - 64px); }
.modal > form, .modal > .modal-b { overflow-y: auto; flex: 1 1 auto; -webkit-overflow-scrolling: touch; }
.modal-h, .modal-f { flex: none; }
.modal.sm { max-width: 520px; }
.modal-h { display: flex; align-items: center; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--line); background: #fff; border-radius: 16px 16px 0 0; }
.modal-h h2 { font-size: 18px; }
.modal-h .x { margin-left: auto; }
.modal-b { padding: 16px 20px; display: grid; gap: 18px; }
.modal-f { display: flex; gap: 8px; justify-content: flex-end; padding: 14px 20px; border-top: 1px solid var(--line); background: #fff; border-radius: 0 0 16px 16px; flex-wrap: wrap; }
.sec { border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; }
.sec > h4 { font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--verde-3); margin-bottom: 12px; display: flex; align-items: center; gap: 8px; }
.sec > h4::before { content: ''; width: 8px; height: 8px; background: var(--laranja); transform: rotate(45deg); }
.total-line { display: flex; justify-content: space-between; align-items: center; background: var(--cinza-1); border-radius: var(--radius-s); padding: 10px 12px; margin-top: 12px; font-weight: 700; }
.timeline { display: grid; gap: 8px; }
.tl { display: grid; grid-template-columns: 90px 1fr; gap: 10px; font-size: 13px; padding: 8px 10px; background: var(--cinza-1); border-radius: var(--radius-s); }
.tl b { font-size: 12px; }

.toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); background: var(--verde); color: #fff; padding: 10px 18px; border-radius: 999px; z-index: 80; font-weight: 600; box-shadow: var(--shadow); }
.toast.bad { background: var(--bad); }
.empty { padding: 30px; text-align: center; color: var(--ink-3); }
.loading { padding: 80px 20px; text-align: center; color: var(--ink-3); }
.defs { display: grid; gap: 10px; }
.defs .d { display: grid; grid-template-columns: 120px 240px 1fr; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.defs .d b { color: var(--verde); }

/* ------------------------------ Meu painel ------------------------------ */
.mp { background: linear-gradient(180deg, color-mix(in srgb, var(--laranja) 8%, #fff) 0, var(--bg) 140px); border: 1px solid color-mix(in srgb, var(--laranja) 22%, #fff); border-radius: 16px; padding: 14px 16px; display: grid; gap: 14px; }
.mp.mp-off { background: #fff; border-color: var(--line); padding: 10px 14px; }
.mp-head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.mp-title { font-size: 17px; font-weight: 800; color: var(--verde); }
.mp-act { margin-left: auto; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.mp-body { display: grid; gap: 14px; }
.mp-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr); gap: 14px; }
.mp-meta { padding: 8px 0; border-bottom: 1px solid var(--line); }
.mp-meta:last-child { border-bottom: 0; }
.mp-lb { font-size: 12px; font-weight: 700; color: var(--ink-2); text-transform: uppercase; letter-spacing: .04em; }
.mp-big { font-size: 26px; font-weight: 800; letter-spacing: -.02em; margin: 2px 0 8px; font-variant-numeric: tabular-nums; }
.mp-meter { height: 12px; position: relative; overflow: visible; }
.mp-meter > b { position: absolute; top: -4px; bottom: -4px; width: 2px; background: var(--verde); }
.mp-foot { font-size: 12.5px; color: var(--ink-2); margin-top: 8px; }
.up { color: var(--good); font-weight: 700; } .dn { color: var(--bad); font-weight: 700; } .warn { color: var(--warn); font-weight: 700; }
.mp-acoes { display: grid; gap: 6px; }
.mp-acao { display: grid; grid-template-columns: 10px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 8px 10px; border: 1px solid var(--line); border-radius: var(--radius-s); cursor: pointer; font-size: 13px; background: #fff; }
.mp-acao:hover { border-color: var(--laranja-3); }
.mp-acao .muted { font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mp-acao > span:last-child { font-size: 12px; text-align: right; }
.dot { width: 10px; height: 10px; border-radius: 50%; background: var(--cinza-2); }
.dot.dn { background: var(--bad); } .dot.warn { background: var(--warn); }
.mp-sub { font-size: 12px; font-weight: 700; color: var(--verde-3); text-transform: uppercase; letter-spacing: .05em; margin: 4px 0 8px; }
.mp-comp + .mp-comp { margin-top: 16px; }
.mp-strip { position: relative; height: 18px; background: var(--cinza-1); border-radius: 999px; }
.mp-strip span { position: absolute; top: 0; bottom: 0; }
.mp-strip .band { background: var(--gelo); border-radius: 999px; }
.mp-strip .med { width: 2px; background: var(--verde-3); }
.mp-strip .alvo { width: 0; border-left: 2px dashed var(--laranja-ink); top: -3px; bottom: -3px; }
.mp-strip .me { width: 14px; height: 14px; top: 2px; margin-left: -7px; border-radius: 50%; background: var(--laranja); border: 2px solid #fff; box-shadow: 0 0 0 1px var(--laranja-ink); }
.mp-key { display: flex; gap: 14px; flex-wrap: wrap; font-size: 11.5px; color: var(--ink-3); margin-top: 8px; }
.mp-key i { display: inline-block; width: 14px; height: 10px; margin-right: 5px; vertical-align: -1px; border-radius: 3px; }
.mp-key .k-band { background: var(--gelo); } .mp-key .k-med { width: 2px; background: var(--verde-3); }
.mp-key .k-alvo { width: 0; border-left: 2px dashed var(--laranja-ink); } .mp-key .k-me { width: 10px; border-radius: 50%; background: var(--laranja); }
.mp-foco { background: #FFF7E8; border: 1px solid #F5DEB0; border-radius: var(--radius-s); padding: 8px 12px; font-size: 13px; margin-bottom: 10px; }
.mp-foco.ok { background: #E9F6EE; border-color: #BFE3CB; }
.mp-badges { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.mp-badge { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border-radius: var(--radius); border: 1px dashed var(--cinza-2); background: #FBFBFA; font-size: 13px; }
.mp-badge .ic { width: 34px; height: 34px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 16px; background: var(--cinza-1); color: var(--ink-3); flex: none; }
.mp-badge.on { border-style: solid; border-color: color-mix(in srgb, var(--laranja) 28%, #fff); background: color-mix(in srgb, var(--laranja) 6%, #fff); }
.mp-badge.on .ic { background: var(--laranja); color: var(--on-laranja); }
.mp-badge .muted { font-size: 12px; }
.aval-ro { display: flex; flex-wrap: wrap; gap: 6px; }
.aval-chip { font-size: 12.5px; padding: 4px 10px; border-radius: 999px; border: 1px solid var(--line); background: #FFF6EA; }
.aval-chip.forte { background: #E9F6EE; }
.crit-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.crit-h { font-size: 13px; margin-bottom: 6px; }
.crit-sub { font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-3); margin: 10px 0 4px; }
.crit { padding: 3px 0; }
.crit label { display: flex; gap: 8px; align-items: flex-start; font-size: 13px; cursor: pointer; }
.crit label input { margin-top: 3px; width: 16px; height: 16px; accent-color: var(--laranja); flex: none; }
.crit.forte label input { accent-color: var(--good); }
.crit-obs { margin: 4px 0 4px 24px; min-height: 32px; padding: 5px 9px; font-size: 13px; width: calc(100% - 24px); }

/* ------------------------------ Ajuda integrada ------------------------------ */
.help-bg { position: fixed; inset: 0; background: rgba(13, 43, 24, .35); z-index: 90; display: flex; justify-content: flex-end; }
.help-panel { width: min(600px, 100%); height: 100%; background: #fff; display: flex; flex-direction: column; box-shadow: -12px 0 40px rgba(0, 0, 0, .18); }
.help-h { display: flex; align-items: center; gap: 10px; padding: 14px 16px 14px 20px; background: var(--verde); color: #fff; }
.help-h > svg { width: 22px; height: 22px; color: var(--laranja); }
.help-h b { font-size: 16px; }
.help-h .btn { margin-left: auto; color: #fff; }
.help-nav { display: flex; gap: 6px; overflow-x: auto; padding: 10px 16px; border-bottom: 1px solid var(--line); flex: none; }
.help-nav button { border: 1px solid var(--cinza-2); background: #fff; border-radius: 999px; padding: 5px 12px; font-size: 12.5px; font-weight: 600; color: var(--ink-2); white-space: nowrap; cursor: pointer; }
.help-nav button.on { background: var(--laranja); border-color: var(--laranja); color: var(--on-laranja); }
.help-b { overflow-y: auto; padding: 16px 20px 40px; font-size: 14px; line-height: 1.55; }
.help-b h2 { font-size: 19px; margin-bottom: 10px; color: var(--verde); }
.help-b p { margin: 10px 0; }
.help-b ul, .help-b ol { padding-left: 20px; margin: 8px 0; }
.help-b li { margin: 4px 0; }
.help-b .table-wrap { margin: 10px 0 14px; border: 1px solid var(--line); border-radius: var(--radius-s); }
.help-b table.t th { position: static; white-space: normal; }
.help-b table.t td { vertical-align: top; }

/* ------------------------------ Responsivo ------------------------------ */
@media (max-width: 1180px) {
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 960px) {
  .app { grid-template-columns: minmax(0, 1fr); background: none; }
  .sidebar { display: none; }
  .mobilebar { display: flex; align-items: center; gap: 10px; background: var(--verde); color: #fff; padding: 10px 16px; position: sticky; top: 0; z-index: 20; }
  .mobilebar img { height: 26px; }
  .mobilebar .sp { flex: 1; }
  .mobilebar button { background: none; border: 0; color: #fff; padding: 6px; }
  .bottomnav { display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; bottom: 0; left: 0; right: 0; background: #fff; border-top: 1px solid var(--line); z-index: 30; padding-bottom: env(safe-area-inset-bottom); }
  .bottomnav a { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 0 7px; font-size: 11px; color: var(--ink-3); text-decoration: none; font-weight: 600; }
  .bottomnav a svg { width: 22px; height: 22px; }
  .bottomnav a.active { color: var(--laranja-ink); }
  .content { padding: 10px 16px 96px; }
  .topbar { padding: 14px 16px 4px; flex-wrap: wrap; }
  .demo-banner { padding: 8px 16px; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .span-2 { grid-column: auto; }
  .login { grid-template-columns: 1fr; }
  .login-art { padding: 28px 22px; min-height: 230px; }
  .login-art h1 { font-size: 26px; }
  .defs .d { grid-template-columns: 1fr; gap: 2px; }
  .drawer { position: fixed; inset: 0; z-index: 60; background: rgba(13, 43, 24, .5); }
  .drawer .sidebar { display: flex; width: 270px; height: 100%; }
}
@media (max-width: 720px) {
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .kpi { padding: 12px; }
  .kpi .vl { font-size: 19px; }
  .grid-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-form .s3, .grid-form .s4 { grid-column: span 2; }
  .tbl-orc { display: none; }
  .mp-grid, .crit-grid { grid-template-columns: 1fr; }
  .mp-t thead { display: none; }
  .mp-t, .mp-t tbody { display: block; }
  .mp-t tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 10px; padding: 10px 0; border-bottom: 1px solid var(--line); }
  table.t.mp-t td { display: block; border: 0; padding: 0; }
  .mp-t td.c-strip, .mp-t td.c-faixa, .mp-t td.c-tend { grid-column: 1 / -1; min-width: 0 !important; }
  table.t.mp-t td.c-med, table.t.mp-t td.c-ref { text-align: left; font-size: 12px; }
  .mp-t td[data-lb]::before { content: attr(data-lb) ': '; color: var(--ink-3); font-weight: 400; }
  .mp-t td.c-tend { white-space: normal; font-size: 12.5px; }
  .mp { padding: 12px; }
  .mp-act { width: 100%; justify-content: flex-start; }
  .mp-acao { grid-template-columns: 10px minmax(0, 1fr); }
  .mp-acao > span:last-child { grid-column: 2; text-align: left; }
  .olist { display: grid; gap: 10px; }
  .filters { border-radius: var(--radius); }
  .filters select, .filters input:not([type=checkbox]) { flex: 1 1 140px; max-width: none; }
  .ftoggle { display: inline-flex !important; }
  .filters.collapsed > :not(.ftoggle):not(.count) { display: none; }
  .demo-banner .long { display: none; }
  .modal-bg { padding: 0; }
  .modal { border-radius: 0; height: 100vh; height: 100dvh; max-height: none; }
  .modal-h, .modal-f { border-radius: 0; }
  .podium { grid-template-columns: 1fr; }
  .chart-box { height: 240px; }
  .topbar .actions { width: 100%; }
  .topbar .actions .btn { flex: 1; }
  .topbar .actions #btn-help { display: none; }
}
@media print {
  .sidebar, .mobilebar, .bottomnav, .filters, .topbar .actions, .demo-banner { display: none !important; }
  .app { display: block; }
  .card, .kpi { box-shadow: none; break-inside: avoid; }
}
.crit-done { display: flex; gap: 8px; align-items: flex-start; font-size: 12.5px; font-weight: 600; padding: 6px 8px; background: var(--cinza-1); border-radius: var(--radius-s); margin-bottom: 4px; cursor: pointer; }
.crit-done input { margin-top: 2px; accent-color: var(--verde); width: 16px; height: 16px; flex: none; }
.crit-done .muted { font-weight: 400; }

/* ===================== Multiempresa: marca, banners, plataforma ===================== */
.wordmark { display: inline-block; font-weight: 800; font-size: 20px; letter-spacing: -.01em; color: #fff; line-height: 1.15; max-width: 100%; overflow-wrap: anywhere; }
.wordmark.dark { color: var(--verde); font-size: 24px; }
.wordmark.big { font-size: 30px; }
.login-art .wordmark.big { color: #fff; }
.login-art .plat-logo { height: 54px; width: auto; align-self: flex-start; position: relative; }
.login-art::before { content: ''; position: absolute; left: 30px; top: 0; bottom: 0; width: 3px; background: repeating-linear-gradient(var(--laranja) 0 22px, transparent 22px 34px); opacity: .9; }
.login-art::after { content: ''; position: absolute; inset: 0; background-image: linear-gradient(rgba(255,255,255,.04) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.04) 1px, transparent 1px); background-size: 44px 44px; pointer-events: none; }
.login-art > * { position: relative; z-index: 1; }
.login-art h1 { font-family: 'Barlow Semi Condensed', var(--font); font-weight: 700; letter-spacing: -.01em; }
.login-art h1 em { font-style: normal; color: var(--laranja); }
.logo-box { display: inline-flex; align-items: center; background: #fff; border-radius: 8px; padding: 6px 10px; max-width: 100%; }
.logo-box img { max-height: 42px; max-width: 180px; width: auto !important; display: block; }
.sidebar .brand .logo-box img { max-height: 40px; }
.mobilebar .wordmark { font-size: 16px; }
.mobilebar .logo-box { padding: 3px 8px; } .mobilebar .logo-box img { max-height: 22px; }
.pend-logo img { width: 160px; } .pend-logo .logo-box img { width: auto; }
.support-banner { background: #FFF1E0; color: #6A3F00; }
.support-banner .btn { margin-left: auto; }
.trial-banner { background: var(--gelo-2); }
.funil { display: grid; gap: 10px; margin-top: 6px; }
.funil-r { display: grid; grid-template-columns: minmax(150px, 1.2fr) 2fr 44px; gap: 10px; align-items: center; font-size: 13px; }
.funil-r b { text-align: right; font-variant-numeric: tabular-nums; }
.funil-b { height: 14px; background: var(--cinza-1); border-radius: 7px; overflow: hidden; }
.funil-b i { display: block; height: 100%; background: var(--laranja); border-radius: 7px; }
.disc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 8px; margin-top: 8px; }
.disc-row { display: grid; grid-template-columns: auto 1fr; gap: 8px; align-items: center; }
label.chk { display: flex; gap: 8px; align-items: center; font-size: 13px; color: var(--ink-2); font-weight: 500; }
label.chk input { width: auto; min-height: 0; }
.mk-prev { margin-top: 12px; }
.mk-side { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; border-radius: 10px; }
.mk-side img { max-height: 40px; max-width: 170px; }
.mk-btn { color: var(--on-laranja); font-weight: 700; padding: 6px 14px; border-radius: 8px; font-size: 13px; }
.hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.signup-cta { display: grid; gap: 8px; text-align: center; margin-top: 10px; padding-top: 14px; border-top: 1px solid var(--line); }
.signup-cta .btn { justify-content: center; text-decoration: none; }
@media (max-width: 760px) { .funil-r { grid-template-columns: 1fr 1fr 36px; } .support-banner .btn { margin-left: 0; } }
@media (max-width: 760px) { .card-head { flex-wrap: wrap; } }
@media (max-width: 760px) { .login-art::before { display: none; } }
