/* ==========================================================================
   NovaLink Sales — identidade visual própria
   SaaS comercial: muito branco, roxo, coral e verde, avatares,
   cards bem arredondados, navegação em cápsula flutuante e animações leves.
   ========================================================================== */

:root {
  --violet: #6c4df6;
  --violet-strong: #5536e0;
  --violet-soft: #f2eeff;
  --lilac: #c9bdfd;
  --coral: #ff6f61;
  --coral-soft: #fff0ee;
  --green: #14b884;
  --green-soft: #e5f8f0;
  --amber: #f2a63b;
  --amber-soft: #fff5e6;
  --sky: #3aa6f2;
  --sky-soft: #e8f5fe;
  --pink: #ec5fa8;
  --ink: #1d1a38;
  --ink-2: #4a4668;
  --muted: #7a7695;
  --line: #eceaf5;
  --line-strong: #dedaf0;
  --bg: #fbfaff;
  --white: #ffffff;
  --radius: 20px;
  --radius-sm: 12px;
  --shadow: 0 1px 2px rgba(35, 25, 90, .04), 0 8px 24px rgba(35, 25, 90, .05);
  --shadow-lift: 0 12px 32px rgba(88, 60, 220, .14);
  --gradient: linear-gradient(135deg, #7b5cff 0%, #a25cf6 45%, #ff7a66 100%);
  --ease: cubic-bezier(.2, .8, .2, 1);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 14px/1.5 'Plus Jakarta Sans', 'Segoe UI', Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
h1, h2, h3, p { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--violet); outline-offset: 3px; }
small { font-size: 12px; }
b, strong { font-weight: 700; }

.ico {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.muted { color: var(--muted); }
.grow { flex: 1; min-width: 0; }
.block { display: block; color: var(--muted); margin-top: 2px; }
.right { text-align: right; }
.coral-text { color: var(--coral); }
.t-quente-text { color: var(--coral); }

/* ---------------------------------------------------------------- topo */

.ribbon {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 7px 32px;
  background: var(--violet-soft);
  color: #6e5bbf;
  font-size: 12px;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 28px;
  height: 72px;
  padding: 0 32px;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.brand { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.brand-mark svg { width: 38px; height: 38px; display: block; transition: transform .4s var(--ease); }
.brand:hover .brand-mark svg { transform: rotate(-8deg) scale(1.05); }
.brand-name { font-size: 23px; font-weight: 800; letter-spacing: -1px; }
.brand-name b { color: var(--violet); }
.brand-tag {
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--coral-soft);
  color: var(--coral);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .4px;
}

.search {
  position: relative;
  flex: 1;
  max-width: 460px;
  margin: 0 auto;
}
.search .ico { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); color: var(--muted); }
.search input {
  width: 100%;
  height: 42px;
  padding: 0 18px 0 44px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: #f4f3fa;
  transition: border-color .2s, background .2s, box-shadow .2s;
}
.search input:focus { outline: none; background: var(--white); border-color: var(--lilac); box-shadow: 0 0 0 4px var(--violet-soft); }

.topbar-actions { display: flex; align-items: center; gap: 18px; flex-shrink: 0; }

.team-stack { display: flex; }
.team-stack .avatar { margin-left: -8px; border: 2px solid var(--white); transition: transform .2s var(--ease); }
.team-stack:hover .avatar { transform: translateY(-2px); }

/* navegação em cápsula flutuante */
.dock {
  position: sticky;
  top: 72px;
  z-index: 4;
  display: flex;
  justify-content: center;
  padding: 14px 32px 0;
  pointer-events: none;
}
.dock-inner {
  display: flex;
  gap: 4px;
  max-width: 100%;
  padding: 6px;
  overflow-x: auto;
  scrollbar-width: none;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--white);
  box-shadow: var(--shadow);
  pointer-events: auto;
}
.dock-inner::-webkit-scrollbar { display: none; }
.dock a {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 9px 15px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  transition: background .2s, color .2s;
}
.dock a:hover { background: var(--violet-soft); color: var(--violet); }
.dock a.active { background: var(--gradient); color: var(--white); box-shadow: 0 6px 16px rgba(108, 77, 246, .3); }

/* ---------------------------------------------------------------- página */

.page { max-width: 1480px; margin: 0 auto; padding: 30px 32px 0; }

.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; margin-bottom: 22px; }
.eyebrow {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
}
h1 { font-size: 32px; font-weight: 800; letter-spacing: -1.2px; line-height: 1.2; }
.sparkle { display: inline-block; margin-left: 10px; color: var(--coral); animation: twinkle 3s ease-in-out infinite; }
.page-head p { margin-top: 6px; color: var(--muted); }

.hint, .footnote { color: var(--muted); font-size: 12px; }
.hint { display: flex; align-items: center; gap: 8px; margin: 4px 0 16px; }
.footnote { margin: 14px 4px 0; line-height: 1.7; }

/* ---------------------------------------------------------------- botões, chips, tags */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  transition: transform .15s var(--ease), box-shadow .2s, background .2s;
}
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--violet); color: var(--white); box-shadow: 0 6px 16px rgba(108, 77, 246, .28); }
.btn-primary:hover { background: var(--violet-strong); box-shadow: var(--shadow-lift); }
.btn-coral { background: var(--coral); color: var(--white); }
.btn-soft { background: var(--violet-soft); color: var(--violet); }
.btn-soft:hover { background: #e6dffe; }
.btn-ghost { border-color: var(--line-strong); background: var(--white); color: var(--ink-2); }
.btn-ghost:hover { border-color: var(--lilac); color: var(--violet); }

.icon-btn {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 50%;
  background: #f4f3fa;
  color: var(--muted);
  font-size: 22px;
  line-height: 1;
}
.icon-btn:hover { background: var(--violet-soft); color: var(--violet); }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--white);
  color: var(--ink-2);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  transition: border-color .2s, color .2s, background .2s;
}
.chip:hover { border-color: var(--lilac); color: var(--violet); }
.chip.active { border-color: var(--violet); background: var(--violet); color: var(--white); }
.chip-muted { color: var(--muted); }
.chip-green { border-color: #bfeedd; background: var(--green-soft); color: #0d8a62; cursor: pointer; }
.chip-query { background: var(--violet-soft); border-color: transparent; color: var(--violet); }
.chip-query a { font-size: 16px; line-height: 1; }

.tag {
  display: inline-block;
  padding: 3px 9px;
  border-radius: 999px;
  background: #f1f0f7;
  color: var(--ink-2);
  font-size: 11px;
  font-style: normal;
  font-weight: 700;
  white-space: nowrap;
}
.tag-coral, .tag-recusada, .tag-descartado { background: var(--coral-soft); color: #e0503f; }
.tag-amber, .tag-rascunho, .tag-em-contato { background: var(--amber-soft); color: #b8741a; }
.tag-aceita, .tag-convertido, .tag-cliente { background: var(--green-soft); color: #0d8a62; }
.tag-enviada, .tag-qualificado { background: var(--violet-soft); color: var(--violet); }
.tag-em-revisao, .tag-novo { background: var(--sky-soft); color: #1f7fc4; }
.tag-prospect { background: #f1f0f7; color: var(--muted); }

.source {
  display: inline-block;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--violet-soft);
  color: #7a61d9;
  font-size: 11px;
  font-weight: 600;
}

.link { color: var(--violet); font-size: 13px; font-weight: 700; }
.link:hover { text-decoration: underline; }

/* estágios do funil */
.stage-pill {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}
.s-lead { background: #efedf8; color: #6d6892; }
.s-qualificacao { background: var(--violet-soft); color: var(--violet); }
.s-proposta { background: var(--amber-soft); color: #b8741a; }
.s-negociacao { background: var(--sky-soft); color: #1f7fc4; }
.s-ganho { background: var(--green-soft); color: #0d8a62; }
.s-perdido { background: var(--coral-soft); color: #e0503f; }

/* ---------------------------------------------------------------- avatares */

.avatar {
  display: inline-grid;
  place-items: center;
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--violet-soft);
  color: var(--violet);
  font-size: 12px;
  font-weight: 800;
  vertical-align: middle;
}
.avatar.xs { width: 22px; height: 22px; font-size: 9px; }
.avatar.sm { width: 30px; height: 30px; font-size: 11px; }
.avatar.lg { width: 48px; height: 48px; font-size: 15px; }
.avatar.xl { width: 72px; height: 72px; font-size: 22px; }
.avatar.c1 { background: #ece6ff; color: #6c4df6; }
.avatar.c2 { background: #ffe9e6; color: #e3513f; }
.avatar.c3 { background: #dcf6ec; color: #0e9a6d; }
.avatar.c4 { background: #e2f1fd; color: #1f7fc4; }
.avatar.c5 { background: #fff1db; color: #c27812; }
.avatar.c6 { background: #fde6f2; color: #c9398a; }
.avatar.ghost { background: #f3f2f8; color: var(--ink-2); }
.avatar.more { background: var(--ink); color: var(--white); }

/* ---------------------------------------------------------------- filtros e barras de ferramentas */

.filterbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 22px;
}
.owner-chips { display: flex; flex-wrap: wrap; gap: 8px; min-width: 0; }
.chip-avatar { padding: 4px 12px 4px 4px; }
.chip-avatar.active .avatar { background: var(--white); color: var(--violet); }
.filterbar-tools { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }

.toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 16px;
}
.toolbar-right { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }

.tabs {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 4px;
  border-radius: 999px;
  background: #f1f0f8;
}
.tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}
.tab b { color: var(--ink-2); font-size: 11px; }
.tab:hover { color: var(--violet); }
.tab.active { background: var(--white); color: var(--ink); box-shadow: 0 2px 8px rgba(35, 25, 90, .08); }
.tabs.small .tab { padding: 6px 11px; font-size: 12px; }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; }

/* ---------------------------------------------------------------- mensagens */

.toasts { position: fixed; right: 24px; bottom: 24px; z-index: 20; display: grid; gap: 10px; }
.toast {
  max-width: 380px;
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  background: var(--ink);
  color: var(--white);
  box-shadow: 0 16px 40px rgba(29, 26, 56, .25);
  font-weight: 600;
  animation: toast-in .45s var(--ease) both, toast-out .4s ease 5s forwards;
}
.toast.success { border-left: 4px solid var(--green); }
.toast.error { border-left: 4px solid var(--coral); }

/* ---------------------------------------------------------------- cards e grades */

.card {
  min-width: 0;
  margin-bottom: 20px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
  animation: rise .5s var(--ease) both;
}
.card.flush { padding: 0; overflow: hidden; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 16px; }
.card-head h2 { font-size: 16px; font-weight: 800; letter-spacing: -.3px; }
.card h3, h3.sub { margin: 20px 0 12px; font-size: 14px; font-weight: 800; }
.count {
  padding: 2px 9px;
  border-radius: 999px;
  background: #f1f0f8;
  color: var(--ink-2);
  font-size: 12px;
  font-weight: 700;
}

.grid { display: grid; gap: 20px; }
.grid > .card { margin-bottom: 0; }
.grid + .card, .grid + .grid, .grid + section { margin-top: 20px; }
.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-overview { grid-template-columns: minmax(0, .9fr) minmax(0, 1.3fr) minmax(0, 1fr); }
.grid-overview-2 { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr) minmax(0, 1fr); margin-bottom: 20px; }
.funnel-layout { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); margin-bottom: 20px; }
.activities-layout { grid-template-columns: minmax(0, 1fr) 320px; align-items: start; }
.activities-layout > div > .card { margin-bottom: 16px; }

/* KPIs */
.kpis {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}
.kpi {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
  animation: rise .5s var(--ease) both;
  transition: transform .25s var(--ease), box-shadow .25s;
}
.kpi:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.kpi:nth-child(2) { animation-delay: .05s; }
.kpi:nth-child(3) { animation-delay: .1s; }
.kpi:nth-child(4) { animation-delay: .15s; }
.kpi:nth-child(5) { animation-delay: .2s; }
.kpi:nth-child(6) { animation-delay: .25s; }
.kpi-icon { display: grid; place-items: center; width: 36px; height: 36px; margin-bottom: 8px; border-radius: 12px; }
.kpi-label { color: var(--muted); font-size: 12px; font-weight: 600; }
.kpi strong { font-size: 22px; letter-spacing: -.8px; overflow-wrap: anywhere; }
.kpi small { color: var(--muted); }
.violet { background: var(--violet-soft); color: var(--violet); }
.sky { background: var(--sky-soft); color: var(--sky); }
.mint { background: var(--green-soft); color: var(--green); }
.coral { background: var(--coral-soft); color: var(--coral); }
.peach { background: var(--amber-soft); color: var(--amber); }
.lilac { background: #f6f2ff; color: #9b7cf7; }

/* linha de estatísticas das seções */
.stat-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}
.stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  animation: rise .5s var(--ease) both;
}
.stat > span { color: var(--muted); font-size: 12px; font-weight: 600; }
.stat strong { font-size: 24px; letter-spacing: -.8px; }
.stat small { color: var(--muted); }

/* pares rótulo/valor */
.pairs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 16px 0 0; }
.pairs.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.pairs.inline { display: flex; flex-wrap: wrap; gap: 24px; margin: 0; }
.pairs div { min-width: 0; }
.pairs dt { color: var(--muted); font-size: 12px; }
.pairs dd { margin: 2px 0 0; font-weight: 800; }

/* barras horizontais genéricas */
.bar { height: 8px; border-radius: 999px; background: #f0eef8; overflow: hidden; }
.bar.thin { height: 6px; }
.bar.big { height: 12px; margin: 16px 0 8px; }
.bar i {
  display: block;
  width: var(--w, 0);
  height: 100%;
  border-radius: inherit;
  background: var(--gradient);
  animation: grow-x .9s var(--ease) both;
  transform-origin: left;
}
.bar i.violet { background: var(--violet); }
.bar i.lilac { background: var(--lilac); }
.bar i.green { background: var(--green); }
.bar i.coral { background: var(--coral); }

/* ---------------------------------------------------------------- início */

.goal-card { text-align: center; }
.goal-card .pairs { text-align: left; }
.ring-wrap { position: relative; width: 170px; margin: 0 auto; }
.ring { display: block; width: 100%; transform: rotate(-90deg); }
.ring circle { fill: none; stroke-width: 10; }
.ring-track { stroke: #f0eef8; }
.ring-value { stroke: url(#nl-grad); stroke-linecap: round; animation: ring-draw 1.2s var(--ease) both; }
.ring-label { position: absolute; inset: 0; display: grid; place-content: center; }
.ring-label strong { font-size: 30px; letter-spacing: -1px; }
.ring-label small { color: var(--muted); }

.month-bars { display: flex; align-items: flex-end; gap: 12px; height: 220px; }
.month { display: flex; flex-direction: column; align-items: center; flex: 1; min-width: 0; height: 100%; gap: 6px; }
.month-value { color: var(--ink-2); font-size: 11px; font-weight: 700; white-space: nowrap; }
.month-track { position: relative; flex: 1; width: 100%; max-width: 46px; }
.month-track i {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--h);
  border-radius: 12px 12px 6px 6px;
  background: linear-gradient(180deg, #8f74ff, #6c4df6);
  transform-origin: bottom;
  animation: grow-y .9s var(--ease) both;
}
.month:last-child .month-track i { background: linear-gradient(180deg, #ff9a8d, #ff6f61); }
.month-label { font-size: 12px; font-weight: 700; }
.month small { color: var(--muted); font-size: 11px; }

.leaderboard, .agenda, .hot-leads, .plain-list, .share-list, .forecast-months, .mini-activities, .timeline {
  margin: 0;
  padding: 0;
  list-style: none;
}
.leaderboard li, .agenda li, .hot-leads li, .plain-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
}
.leaderboard li:last-child, .agenda li:last-child, .hot-leads li:last-child, .plain-list li:last-child { border-bottom: 0; }
.leaderboard .bar { margin-top: 6px; }
.agenda small, .hot-leads small, .plain-list small { display: block; color: var(--muted); }
.plain-list span:last-child { min-width: 0; }
.num { text-align: right; font-weight: 800; white-space: nowrap; }
.num small { display: block; color: var(--muted); font-weight: 600; }

.medal {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #f1f0f8;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  flex-shrink: 0;
}
.medal.m1 { background: linear-gradient(135deg, #ffd66b, #f2a63b); color: var(--white); }
.medal.m2 { background: linear-gradient(135deg, #dcdbe8, #a9a6c0); color: var(--white); }
.medal.m3 { background: linear-gradient(135deg, #ffb59a, #e0785a); color: var(--white); }

.due { color: var(--muted); font-size: 12px; font-weight: 700; white-space: nowrap; }
.due.late, small.late { color: var(--coral); }

.score {
  display: inline-grid;
  place-items: center;
  min-width: 38px;
  height: 28px;
  padding: 0 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}
.t-quente { background: var(--coral-soft); color: #e0503f; }
.t-morno { background: var(--amber-soft); color: #b8741a; }
.t-frio { background: var(--sky-soft); color: #1f7fc4; }
.bar i.t-quente { background: var(--coral); }
.bar i.t-morno { background: var(--amber); }
.bar i.t-frio { background: var(--sky); }
.dot.t-quente { background: var(--coral); }
.dot.t-morno { background: var(--amber); }
.dot.t-frio { background: var(--sky); }

.win-strip { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.win {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 16px;
  border-radius: 16px;
  background: linear-gradient(160deg, var(--green-soft), var(--white) 70%);
  border: 1px solid #d3f2e6;
  overflow: hidden;
  transition: transform .25s var(--ease), box-shadow .25s;
}
.win:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(20, 184, 132, .15); }
.win small { color: var(--muted); }
.win strong { margin-top: 8px; font-size: 20px; color: #0d8a62; }
.win-foot { display: flex; align-items: center; gap: 6px; margin-top: 6px; color: var(--muted); font-size: 12px; }
.confetti { position: absolute; right: 14px; top: 10px; color: var(--green); animation: twinkle 2.6s ease-in-out infinite; }

/* ---------------------------------------------------------------- funil */

.funnel { display: grid; gap: 10px; }
.funnel-row { display: grid; grid-template-columns: 110px minmax(0, 1fr) 120px; align-items: center; gap: 14px; }
.funnel-stage { font-size: 13px; font-weight: 700; }
.funnel-track { display: flex; justify-content: center; }
.funnel-bar {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  width: var(--w);
  min-width: 64px;
  height: 42px;
  border-radius: 14px;
  color: var(--white);
  font-size: 13px;
  white-space: nowrap;
  animation: grow-x .9s var(--ease) both;
}
.funnel-bar span { opacity: .85; font-size: 12px; }
.funnel-bar.f1 { background: #9d8bff; }
.funnel-bar.f2 { background: #7d62ff; animation-delay: .08s; }
.funnel-bar.f3 { background: #6c4df6; animation-delay: .16s; }
.funnel-bar.f4 { background: #ff8a7a; animation-delay: .24s; }
.funnel-bar.f5 { background: var(--green); animation-delay: .32s; }
.funnel-rate { font-size: 15px; font-weight: 800; text-align: right; }
.funnel-rate small { display: block; color: var(--muted); font-size: 11px; font-weight: 600; }
.funnel-foot { margin-top: 8px; color: var(--muted); font-size: 13px; }
.funnel-foot b { color: var(--ink); }
.funnel-compact .funnel-row { grid-template-columns: 90px minmax(0, 1fr) 56px; }
.funnel-compact .funnel-bar { height: 32px; border-radius: 10px; }
.funnel + .table-scroll { margin-top: 18px; }

.share-list li {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 9px 0;
  font-size: 13px;
}
.share-list.wide li { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) 80px; }
.share-list li > b { text-align: right; }
.share-list small { color: var(--muted); }

/* ---------------------------------------------------------------- tabelas */

.table-scroll { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: 13px; }
.table th {
  padding: 13px 16px;
  background: #faf9fe;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  text-align: left;
  white-space: nowrap;
}
.table th.right { text-align: right; }
.table td { padding: 13px 16px; border-top: 1px solid var(--line); vertical-align: middle; }
.table tbody tr { transition: background .15s; }
.table tbody tr:hover { background: #fcfbff; }
.table.compact td, .table.compact th { padding: 9px 12px; }
.table .empty { padding: 30px; color: var(--muted); text-align: center; }
.card .table-scroll .table th:first-child, .card .table-scroll .table td:first-child { padding-left: 20px; }

.who { display: flex; align-items: center; gap: 10px; min-width: 0; }
.who small { display: block; color: var(--muted); }
.score-cell { display: flex; align-items: center; gap: 10px; min-width: 120px; }
.score-cell .bar { flex: 1; }
.row-actions { display: inline-flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
form.inline { display: inline-flex; flex-wrap: wrap; gap: 6px; }

/* popover de conversão */
.pop { position: relative; display: inline-block; }
.pop summary { list-style: none; }
.pop summary::-webkit-details-marker { display: none; }
.pop-body {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  z-index: 6;
  width: 300px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--white);
  box-shadow: 0 20px 50px rgba(35, 25, 90, .18);
  text-align: left;
  animation: rise .25s var(--ease) both;
}

/* ---------------------------------------------------------------- kanban */

.kanban {
  display: grid;
  grid-template-columns: repeat(6, minmax(250px, 1fr));
  gap: 16px;
  padding-bottom: 16px;
  overflow-x: auto;
}
.column {
  min-width: 0;
  padding: 14px;
  border-radius: var(--radius);
  background: #f5f4fb;
  border-top: 4px solid var(--stage, var(--lilac));
  transition: background .2s, box-shadow .2s;
}
.col-1 { --stage: #b3acd8; }
.col-2 { --stage: var(--violet); }
.col-3 { --stage: var(--amber); }
.col-4 { --stage: var(--sky); }
.col-5 { --stage: var(--green); }
.col-6 { --stage: var(--coral); }
.column-head { display: flex; align-items: center; gap: 8px; }
.column-head h2 { font-size: 14px; font-weight: 800; }
.column-head .count { margin-left: auto; background: var(--white); }
.stage-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--stage); }
.column-total { margin: 6px 0 14px 17px; color: var(--ink-2); font-size: 13px; font-weight: 700; }
.column-total small { color: var(--muted); font-weight: 600; }
.drop-zone { display: grid; gap: 10px; min-height: 80px; }
.drag-target { background: var(--violet-soft); box-shadow: inset 0 0 0 2px var(--lilac); }

.deal {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--white);
  box-shadow: 0 1px 2px rgba(35, 25, 90, .04);
  cursor: grab;
  animation: rise .4s var(--ease) both;
  transition: transform .2s var(--ease), box-shadow .2s, border-color .2s;
}
.deal:hover { transform: translateY(-2px); border-color: var(--lilac); box-shadow: var(--shadow-lift); }
.deal.dragging { opacity: .5; transform: rotate(2deg); }
.deal-top { display: flex; flex-wrap: wrap; gap: 5px; }
.deal-link { display: block; margin-top: 10px; }
.deal-link h3 { font-size: 14px; font-weight: 800; }
.deal-link p { margin-top: 2px; color: var(--muted); font-size: 12px; }
.deal-link:hover h3 { color: var(--violet); }
.deal-amount { display: block; margin: 12px 0; font-size: 16px; letter-spacing: -.3px; }
.deal-bottom { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.deal-bottom small { display: inline-flex; align-items: center; gap: 4px; color: var(--muted); }
.deal-bottom .ico { width: 14px; height: 14px; }
.next-step { margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--line-strong); color: var(--ink-2); font-size: 12px; }
.next-step.lost { color: #e0503f; }
.empty-column {
  padding: 18px;
  border: 1.5px dashed var(--line-strong);
  border-radius: 14px;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}

/* ---------------------------------------------------------------- empresas */

.count-line { margin: 0 4px 12px; font-size: 13px; }
.company-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.company-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
  animation: rise .5s var(--ease) both;
  transition: transform .25s var(--ease), box-shadow .25s, border-color .25s;
}
.company-card:hover { transform: translateY(-3px); border-color: var(--lilac); box-shadow: var(--shadow-lift); }
.company-top { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 10px; }
.company-logo {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: var(--gradient);
  color: var(--white);
  font-weight: 800;
}
.company-logo.big { width: 64px; height: 64px; border-radius: 18px; font-size: 20px; }
.company-card h2 { font-size: 16px; font-weight: 800; }
.company-card > p { color: var(--muted); font-size: 12px; }
.company-numbers { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 14px 0; }
.company-numbers small { display: block; color: var(--muted); }
.company-numbers strong { font-size: 16px; }
.company-foot { display: flex; align-items: center; gap: 8px; margin-top: auto; color: var(--muted); }

.company-detail { position: relative; }
.close-detail { position: absolute; top: 18px; right: 18px; }
.company-detail-head { display: flex; flex-wrap: wrap; align-items: center; gap: 18px; padding-right: 44px; }
.company-detail-head h2 { margin: 4px 0 2px; font-size: 22px; font-weight: 800; }
.company-detail-head .pairs { margin-left: auto; }

/* ---------------------------------------------------------------- atividades */

.activity {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 0;
  border-top: 1px solid var(--line);
}
.activity small { display: block; color: var(--muted); }
.activity.done b { color: var(--muted); text-decoration: line-through; }
.agenda-group.g-overdue { border-left: 4px solid var(--coral); }
.agenda-group.g-today { border-left: 4px solid var(--violet); }
.empty-line { padding: 6px 0; font-size: 13px; }

.tick {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  padding: 0;
  border: 2px solid var(--line-strong);
  border-radius: 50%;
  background: var(--white);
  color: var(--white);
  font-size: 12px;
  font-weight: 800;
  transition: border-color .2s, background .2s, transform .2s var(--ease);
}
.tick:hover { border-color: var(--green); transform: scale(1.1); }
.done .tick { border-color: var(--green); background: var(--green); }

.kind-dot { display: inline-block; flex-shrink: 0; width: 10px; height: 10px; margin-right: 4px; border-radius: 50%; background: var(--lilac); }
.k-ligacao { background: var(--sky); }
.k-reuniao { background: var(--violet); }
.k-e-mail { background: var(--amber); }
.k-demonstracao { background: var(--coral); }
.k-tarefa { background: var(--green); }
.bar i.k-ligacao { background: var(--sky); }
.bar i.k-reuniao { background: var(--violet); }
.bar i.k-e-mail { background: var(--amber); }
.bar i.k-demonstracao { background: var(--coral); }
.bar i.k-tarefa { background: var(--green); }

/* ---------------------------------------------------------------- propostas */

.proposal-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.proposal {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
  animation: rise .5s var(--ease) both;
  transition: transform .25s var(--ease), box-shadow .25s;
}
.proposal:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.proposal.is-expiring { border-color: #ffd7a8; }
.proposal.is-expired { border-color: #ffc6bf; }
.proposal header { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 8px; }
.proposal .code { color: var(--muted); font-size: 12px; font-weight: 700; }
.proposal h3 { font-size: 16px; font-weight: 800; }
.proposal a:hover h3 { color: var(--violet); }
.proposal > p { color: var(--muted); font-size: 13px; }
.proposal-values { margin: 12px 0; }
.proposal-values strong { display: block; font-size: 20px; letter-spacing: -.5px; }
.proposal-values small { color: var(--muted); }
.proposal footer { display: flex; align-items: center; gap: 8px; margin-top: auto; color: var(--muted); }

/* ---------------------------------------------------------------- forecast e metas */

.goal-line { margin-bottom: 8px; }
.goal-track { position: relative; height: 18px; margin: 10px 0 10px; border-radius: 999px; background: #f0eef8; }
.goal-fill {
  display: block;
  width: var(--w);
  height: 100%;
  border-radius: inherit;
  background: var(--gradient);
  animation: grow-x 1s var(--ease) both;
  transform-origin: left;
}
.goal-marker { position: absolute; top: -5px; bottom: -5px; width: 3px; border-radius: 3px; background: var(--ink); }
.goal-legend { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 4px; font-size: 13px; }

.forecast-months li {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr) 110px;
  align-items: center;
  gap: 14px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.forecast-months li.late .fm-label { color: var(--coral); }
.fm-label { font-weight: 700; font-size: 13px; }
.fm-label small, .fm-values small { display: block; color: var(--muted); font-weight: 500; }
.fm-bars { display: grid; gap: 5px; }
.fm-values { text-align: right; font-size: 13px; }
.legend { display: flex; gap: 16px; margin-top: 12px; color: var(--muted); font-size: 12px; }
.legend i { display: inline-block; width: 12px; height: 8px; margin-right: 6px; border-radius: 4px; }
.legend i.lilac { background: var(--lilac); }
.legend i.violet { background: var(--violet); }

.stage-weights { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.stage-weights article { display: flex; flex-direction: column; gap: 6px; padding: 16px; border-radius: 16px; background: #faf9fe; }
.stage-weights strong { font-size: 20px; letter-spacing: -.5px; }
.stage-weights small { color: var(--muted); }

.goal-form { display: flex; gap: 6px; align-items: center; }
.goal-form input { width: 120px; padding: 7px 10px; border: 1px solid var(--line-strong); border-radius: 10px; background: var(--white); }

/* ---------------------------------------------------------------- equipe */

.podium {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: end;
  gap: 16px;
  margin-bottom: 24px;
}
.podium-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 26px 18px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--white);
  box-shadow: var(--shadow);
  text-align: center;
  animation: rise .6s var(--ease) both;
}
.podium-card.p1 { order: 2; padding-top: 38px; background: linear-gradient(180deg, #f4efff, var(--white) 60%); border-color: #ddd2ff; }
.podium-card.p2 { order: 1; animation-delay: .1s; }
.podium-card.p3 { order: 3; animation-delay: .2s; }
.podium-card .medal { width: auto; height: auto; padding: 4px 12px; border-radius: 999px; }
.podium-card h2 { font-size: 18px; font-weight: 800; }
.podium-card small { color: var(--muted); }
.podium-card strong { font-size: 26px; letter-spacing: -1px; color: var(--violet); }
.podium-card.p1 .avatar { box-shadow: 0 0 0 4px var(--white), 0 0 0 7px #ffd66b; }

.seller-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.seller-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
  animation: rise .5s var(--ease) both;
}
.seller-card header { display: flex; align-items: center; gap: 12px; }
.seller-card h3 { font-size: 15px; font-weight: 800; }
.seller-card header small { color: var(--muted); }
.seller-card .pairs { margin: 0; }
.rank { color: var(--lilac); font-size: 20px; font-weight: 800; }
.seller-goal { display: grid; gap: 6px; font-size: 13px; }

/* ---------------------------------------------------------------- formulários, modais e painel lateral */

.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.form-grid label, .stage-form label { display: flex; flex-direction: column; gap: 6px; min-width: 0; color: var(--ink-2); font-size: 12px; font-weight: 600; }
.span-2 { grid-column: span 2; }
input, select, textarea {
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: var(--white);
  font-size: 13px;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--violet); box-shadow: 0 0 0 4px var(--violet-soft); }
textarea { resize: vertical; }

.modal {
  width: min(560px, calc(100% - 32px));
  padding: 26px;
  border: 0;
  border-radius: 24px;
  box-shadow: 0 30px 90px rgba(35, 25, 90, .3);
}
.modal[open] { animation: pop .35s var(--ease) both; }
.modal::backdrop { background: rgba(29, 26, 56, .35); backdrop-filter: blur(4px); }
.modal-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 18px; }
.modal-head h2 { font-size: 20px; font-weight: 800; letter-spacing: -.5px; }
.modal > .muted { margin: -8px 0 16px; }

.drawer-backdrop { position: fixed; inset: 0; z-index: 10; background: rgba(29, 26, 56, .3); animation: fade .3s ease both; }
.drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 11;
  width: min(540px, 100%);
  padding: 32px 30px 40px;
  overflow-y: auto;
  background: var(--white);
  box-shadow: -20px 0 60px rgba(35, 25, 90, .18);
  animation: slide-in .45s var(--ease) both;
}
.close-drawer { position: absolute; top: 20px; right: 20px; }
.drawer h2 { font-size: 24px; font-weight: 800; letter-spacing: -.6px; }
.drawer-sub { margin-top: 2px; color: var(--muted); }
.drawer h3 { margin: 26px 0 12px; font-size: 15px; font-weight: 800; }
.drawer-hero { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 18px 0; }
.deal-value { font-size: 28px; letter-spacing: -1px; background: var(--gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }
.drawer-people { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.person { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 14px; background: #faf9fe; min-width: 0; }
.person small { display: block; color: var(--muted); }
.person b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.facts { display: grid; gap: 8px; margin: 16px 0 0; padding: 0; list-style: none; color: var(--ink-2); font-size: 13px; }
.facts li { display: flex; align-items: center; gap: 8px; overflow-wrap: anywhere; }
.facts .ico { color: var(--violet); width: 16px; height: 16px; }
.facts a { color: var(--violet); }

.stage-box { margin-top: 22px; padding: 14px; border-radius: 16px; background: var(--violet-soft); }
.stage-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px; }
.stage-form label { flex: 1 1 160px; }
.lost-reason { display: flex; flex-direction: column; gap: 6px; margin-top: 10px; color: var(--ink-2); font-size: 12px; font-weight: 600; }
.lost-reason[hidden] { display: none; }

.timeline { display: flex; flex-wrap: wrap; gap: 8px; }
.timeline li { display: flex; flex-direction: column; padding: 8px 12px; border-radius: 12px; font-size: 12px; }
.timeline small { opacity: .8; }

.proposal-card { display: grid; gap: 8px; margin-bottom: 14px; padding: 14px; border: 1px solid var(--line); border-radius: 16px; }
.proposal-card small { color: var(--muted); }
.status-row { display: flex; flex-wrap: wrap; gap: 6px; }

.mini-activities { display: grid; gap: 4px; margin-bottom: 12px; }
.mini-activities li { display: flex; align-items: center; gap: 10px; padding: 8px 0; }
.mini-activities small { display: block; color: var(--muted); }
.mini-activities li.done b { color: var(--muted); text-decoration: line-through; }

.note { margin-bottom: 8px; padding: 12px 14px; border-radius: 14px; background: #faf9fe; }
.note small { color: var(--muted); }
.note p { margin-top: 2px; font-size: 13px; line-height: 1.6; }
.drawer .form-grid { margin-top: 10px; }

/* ---------------------------------------------------------------- rodapé */

.foot {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 36px 0 28px;
  color: var(--muted);
  font-size: 12px;
}
.foot a:hover { color: var(--violet); }

/* ---------------------------------------------------------------- animações */

@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes grow-x { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes grow-y { from { transform: scaleY(0); } to { transform: scaleY(1); } }
@keyframes ring-draw { from { stroke-dasharray: 0 100; } }
@keyframes pop { from { opacity: 0; transform: scale(.95) translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes slide-in { from { transform: translateX(40px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes twinkle { 0%, 100% { transform: scale(1) rotate(0); opacity: 1; } 50% { transform: scale(1.25) rotate(20deg); opacity: .7; } }
@keyframes toast-in { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
@keyframes toast-out { to { opacity: 0; transform: translateY(16px); visibility: hidden; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ---------------------------------------------------------------- responsivo */

@media (max-width: 1280px) {
  .kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .grid-overview { grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); }
  .grid-overview > .card:last-child { grid-column: span 2; }
  .grid-overview-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-overview-2 > .card:first-child { grid-column: span 2; }
  .company-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .win-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .chip-avatar .chip-label { display: none; }
  .chip-avatar { padding: 4px; }
}

@media (max-width: 980px) {
  .topbar { gap: 16px; }
  .team-stack { display: none; }
  .grid.two, .funnel-layout, .activities-layout { grid-template-columns: minmax(0, 1fr); }
  .proposal-grid, .seller-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .company-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stage-weights { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .filterbar { flex-direction: column; align-items: stretch; }
  .filterbar-tools { justify-content: flex-end; }
}

@media (max-width: 720px) {
  body { font-size: 13px; }
  .ribbon { padding: 7px 16px; font-size: 11px; }
  .ribbon span:last-child { display: none; }
  .topbar { flex-wrap: wrap; height: auto; padding: 12px 16px; gap: 10px; position: static; }
  .brand-name { font-size: 20px; }
  .search { order: 3; flex-basis: 100%; max-width: none; }
  .topbar-actions { margin-left: auto; }
  .topbar-actions .btn span { display: none; }
  .topbar-actions .btn { padding: 10px 12px; }
  .dock { top: 0; padding: 10px 16px 0; justify-content: flex-start; }
  .dock-inner { width: 100%; }
  .page { padding: 20px 16px 0; }
  h1 { font-size: 24px; }
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .kpi { padding: 14px; }
  .kpi strong { font-size: 18px; }
  .grid-overview, .grid-overview-2 { grid-template-columns: minmax(0, 1fr); }
  .grid-overview > .card:last-child, .grid-overview-2 > .card:first-child { grid-column: auto; }
  .win-strip, .company-grid, .proposal-grid, .seller-grid, .podium { grid-template-columns: minmax(0, 1fr); }
  .podium-card.p1, .podium-card.p2, .podium-card.p3 { order: 0; }
  .stage-weights { grid-template-columns: minmax(0, 1fr); }
  .pairs.three { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .funnel-row { grid-template-columns: 84px minmax(0, 1fr) 60px; gap: 8px; }
  .funnel-rate small { display: none; }
  .funnel-bar span { display: none; }
  .forecast-months li { grid-template-columns: 80px minmax(0, 1fr) 84px; gap: 8px; }
  .month-bars { gap: 6px; height: 190px; }
  .month-value { font-size: 9px; }
  .share-list li, .share-list.wide li { grid-template-columns: minmax(0, 1fr) 70px auto; }
  .kanban { grid-template-columns: repeat(6, minmax(240px, 82vw)); scroll-snap-type: x mandatory; }
  .column { scroll-snap-align: start; }
  .form-grid { grid-template-columns: minmax(0, 1fr); }
  .span-2 { grid-column: auto; }
  .drawer { padding: 24px 18px 32px; }
  .drawer-people { grid-template-columns: minmax(0, 1fr); }
  .company-detail-head .pairs { margin-left: 0; }
  .toasts { left: 16px; right: 16px; }
  .foot { flex-direction: column; }
  .pop-body { width: min(300px, calc(100vw - 48px)); }
  .goal-legend { flex-direction: column; }
}
