:root {
  /* Paleta roxa da proposta visual de referência (pixel-sampled: botão/logo #7056D8). */
  --brand-50: #EFEBFB;
  --brand-100: #E4DCF9;
  --brand-200: #CBBBF2;
  --brand-400: #9B7FE0;
  --brand-600: #7056D8;
  --brand-700: #6D50CC;
  --brand-800: #5A3FB0;
  --brand-900: #452F87;
  --brand-950: #2E1F5C;
  --ink: #0F172A;
  --ink-soft: #475569;
  --ink-faint: #94A3B8;
  --line: #E2E8F0;
  --line-soft: #F1F5F9;
  --paper: #F6F6FB;
  --surface: #FFFFFF;
  --ok: #389E82;
  --ok-pale: #EDF8F4;
  --ok-line: #A7F3D0;
  --warn: #D1A04F;
  --warn-pale: #FFF6E8;
  --warn-line: #FDE68A;
  --danger: #DC2626;
  --danger-pale: #FEF2F2;
  --danger-line: #FECACA;
  --dark-ink: #1E3A8A;
  --dark-ink-soft: #AFC0E4;
  --dark-line: #2E4584;
  --mint: #34D399;
  /* Sidebar clara, como o restante do app — sem bloco escuro. */
  --sidebar-bg: #FFFFFF;
  --sidebar-ink: #0F172A;
  --sidebar-ink-soft: #64748B;
  --sidebar-ink-faint: #94A3B8;
  --sidebar-line: #EEF1F5;
  --sidebar-hover: #F8FAFC;
  --sidebar-active-bg: var(--brand-50);
  --sidebar-active-ink: var(--brand-700);
  --shadow-soft: 0 1px 2px 0 rgba(2, 8, 23, .04), 0 10px 24px -16px rgba(2, 8, 23, .12);
  --shadow-card: 0 1px 3px 0 rgba(2, 8, 23, .08), 0 1px 2px -1px rgba(2, 8, 23, .06);
  --shadow-pop: 0 2px 4px -1px rgba(2, 8, 23, .06), 0 20px 36px -14px rgba(2, 8, 23, .18);
  --shadow-lift: 0 16px 40px -12px rgba(2, 8, 23, .18), 0 2px 8px -4px rgba(2, 8, 23, .08);
  --shadow: var(--shadow-soft);
  /* Escala de raio compartilhada — cards e controles maiores que os botões pequenos. */
  --radius-sm: 9px;
  --radius-md: 13px;
  --radius-lg: 20px;
  --ease: cubic-bezier(.2, .8, .2, 1);
  /* Acento roxo do mascote, reservado para a IA (Victor) — o verde continua sendo a cor da marca. */
  --accent-violet: #7C5CFC;
  --accent-violet-pale: #F1EEFF;
  --accent-violet-line: #DCD3FD;
  font-family: "Inter", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  font-feature-settings: "cv05" 1, "cv11" 1;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; min-width: 320px; background: var(--paper); }
button, input { font: inherit; }
button { cursor: pointer; }
/* Anel de foco e seleção de texto na cor da marca, em vez do azul padrão do navegador. */
:focus-visible { outline: 2px solid var(--brand-400); outline-offset: 2px; }
::selection { color: var(--brand-900); background: var(--brand-200); }

/* Dentro do app o "tinta escura" é o indigo da marca; a landing mantém o azul. */
body:has(> .app-shell) { display: flex; flex-direction: column; min-height: 100vh; --dark-ink: var(--brand-600); --dark-ink-soft: var(--brand-200); --dark-line: var(--brand-700); }
.app-shell { --sidebar-w: 264px; position: relative; display: grid; grid-template-columns: var(--sidebar-w) minmax(0, 1fr); flex: 1; min-height: 0; }
.app-shell::before { content: ""; position: absolute; inset: 0 auto 0 0; width: var(--sidebar-w); background: var(--sidebar-bg); border-right: 1px solid var(--sidebar-line); }
body:has(> .app-shell) h1, body:has(> .app-shell) h2 { font-family: "Inter", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; font-weight: 700; letter-spacing: -.015em; }
.sidebar { position: fixed; top: 0; left: 0; width: var(--sidebar-w); z-index: 2; display: flex; flex-direction: column; height: 100vh; overflow-y: auto; padding: 20px 16px 16px; color: var(--sidebar-ink); background: var(--sidebar-bg); border-right: 1px solid var(--sidebar-line); }
.app-footer { margin-left: var(--sidebar-w, 264px); display: flex; align-items: center; justify-content: space-between; gap: 16px; flex: 0 0 auto; padding: 18px 46px; border-top: 1px solid var(--line); background: var(--surface); }
.app-footer-brand { display: flex; align-items: center; }
.app-footer-brand .brand-logo-full { display: block; height: 26px; width: auto; }
.app-footer-credit { color: var(--ink-faint); font-size: 13px; white-space: nowrap; }
.app-footer-credit strong { margin-left: 4px; color: var(--ink); font-weight: 700; }
.sidebar-top { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 2px 4px 14px; }
.brand-lockup { display: flex; align-items: center; gap: 11px; min-width: 0; overflow: hidden; }
.brand-logo-full { flex: 0 0 auto; height: 34px; width: auto; max-width: 100%; }
img { max-width: 100%; }
.eyebrow, .nav-section-label, .metric-label { display: block; color: var(--ink-faint); font-size: 10px; font-weight: 700; letter-spacing: .1em; line-height: 1.4; text-transform: uppercase; }
.sidebar .eyebrow, .sidebar .nav-section-label { color: var(--sidebar-ink-faint); }
.workspace-switcher { padding: 0 4px 10px; margin-bottom: 2px; }
.gabinete-name { display: flex; align-items: center; gap: 8px; color: var(--sidebar-ink); font-size: 12.5px; font-weight: 600; }
.status-dot { display: inline-block; flex: 0 0 6px; width: 6px; height: 6px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 3px rgba(5, 150, 105, .14); }
.sidebar-divider { height: 1px; margin: 0 4px 10px; background: var(--sidebar-line); }
.main-nav { scrollbar-width: thin; scrollbar-color: var(--sidebar-line) transparent; display: flex; flex: 1; flex-direction: column; gap: 2px; min-height: 0; margin: 0 -4px; padding: 0 4px; overflow-y: auto; }
.nav-section-label { padding: 0; }
.nav-section-spaced { margin-top: 14px; }
/* Grupos recolhíveis — só a seção ativa fica aberta, o resto é 1 linha. */
.nav-group { margin-top: 2px; }
.nav-section-toggle { display: flex; align-items: center; gap: 8px; width: 100%; padding: 10px 12px 6px; border: 0; border-radius: 10px; background: transparent; text-align: left; }
.nav-section-toggle:hover { background: var(--sidebar-hover); }
.nav-section-toggle:hover .nav-section-label { color: var(--sidebar-ink-soft); }
.nav-section-chevron { flex: 0 0 13px; width: 13px; height: 13px; margin-left: auto; color: var(--sidebar-ink-faint); transition: transform .15s var(--ease); }
.nav-group.is-open .nav-section-chevron { transform: rotate(90deg); }
.nav-group-items { display: none; flex-direction: column; gap: 2px; }
.nav-group.is-open .nav-group-items { display: flex; }
.nav-item { position: relative; display: flex; align-items: center; gap: 12px; width: 100%; min-height: 33px; padding: 5px 12px; border: 0; border-radius: 10px; color: var(--sidebar-ink-soft); background: transparent; font-size: 13.5px; font-weight: 500; text-align: left; transition: background .15s ease, color .15s ease; }
.nav-item:hover { color: var(--sidebar-ink); background: var(--sidebar-hover); }
.nav-item.is-active { color: var(--sidebar-active-ink); background: var(--sidebar-active-bg); font-weight: 600; box-shadow: inset 3px 0 0 var(--brand-400); }
.main-nav > [data-view="command"] { position: sticky; top: 0; z-index: 1; background: var(--sidebar-bg); }
.main-nav > [data-view="command"]:hover { background: var(--sidebar-hover); }
.main-nav > [data-view="command"].is-active { background: var(--sidebar-active-bg); }
.nav-icon { display: grid; flex: 0 0 20px; place-items: center; color: var(--sidebar-ink-faint); }
.nav-icon svg { width: 19px; height: 19px; }
.nav-item.is-active .nav-icon { color: var(--brand-700); }
.nav-item:hover .nav-icon { color: var(--sidebar-ink-soft); }
.nav-count { margin-left: auto; padding: 1px 7px; border-radius: 999px; color: var(--sidebar-ink-soft); background: var(--sidebar-hover); font-size: 10px; font-weight: 600; font-variant-numeric: tabular-nums; }
.nav-item.is-active .nav-count { color: var(--brand-700); background: var(--brand-100); }
/* Victor (IA) usa o roxo do mascote na sidebar, em vez do verde ativo do resto do menu. */
.nav-item[data-view="ai"] .nav-icon { color: var(--accent-violet); }
.nav-item[data-view="ai"].is-active { color: #6B46E5; background: var(--accent-violet-pale); box-shadow: inset 3px 0 0 var(--accent-violet); }
.nav-item[data-view="ai"].is-active .nav-icon { color: #6B46E5; }
.sidebar-bottom { flex: 0 0 auto; padding-top: 12px; }
.shortcut { margin-left: auto; color: var(--ink-faint); font-size: 10px; }
.user-chip { display: flex; flex-wrap: nowrap; align-items: center; gap: 10px; padding: 12px; border: 1px solid var(--sidebar-line); border-radius: 14px; background: var(--sidebar-hover); }
.user-chip-id { flex: 1 1 auto; min-width: 0; }
.user-chip strong, .user-chip span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.logout-button { flex: 0 0 auto; }
.avatar { display: grid; place-items: center; flex: 0 0 32px; width: 32px; height: 32px; border-radius: 9px; color: var(--brand-700); background: var(--brand-100); font-size: 11px; font-weight: 700; }
.user-chip strong, .user-chip span { display: block; }
.user-chip strong { color: var(--sidebar-ink); font-size: 12px; font-weight: 600; }
.user-chip span { margin-top: 2px; color: var(--sidebar-ink-faint); font-size: 10.5px; }
.icon-button { border: 0; color: inherit; background: transparent; }
.logout-button { display: flex; align-items: center; gap: 5px; margin-left: auto; padding: 5px 8px; border: 0; border-radius: 6px; color: var(--sidebar-ink-faint); background: transparent; font-size: 11px; font-weight: 600; white-space: nowrap; }
.logout-button svg { width: 13px; height: 13px; }
.logout-button:hover { color: var(--danger); background: var(--danger-pale); }

.main-content { grid-column: 2; min-width: 0; background: var(--paper); }
.topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; height: 68px; padding: 0 46px; background: var(--surface); border-bottom: 1px solid var(--line); }
.topbar-left { display: flex; align-items: center; gap: 16px; min-width: 0; }
.topbar .breadcrumbs { display: flex; align-items: center; gap: 8px; }
.sidebar-toggle { display: none; align-items: center; justify-content: center; width: 38px; height: 38px; margin-right: 10px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); color: var(--ink); cursor: pointer; }
.sidebar-toggle svg { width: 20px; height: 20px; }
.sidebar-backdrop { display: none; position: fixed; inset: 0; z-index: 30; background: rgba(15, 23, 42, .4); }
.sidebar-backdrop.is-open { display: block; }
.breadcrumbs { display: flex; align-items: center; gap: 8px; min-width: 0; color: var(--ink-faint); font-size: 13px; }
.breadcrumbs b { flex: 0 0 auto; color: var(--ink-faint); font-weight: 400; font-style: normal; }
.breadcrumbs span, .breadcrumbs strong { overflow: hidden; max-width: 220px; white-space: nowrap; text-overflow: ellipsis; }
.breadcrumbs strong { color: var(--ink); font-weight: 600; }
.topbar-actions { display: flex; align-items: center; gap: 14px; }
.topbar-user-wrap { position: relative; }
.topbar-user { display: flex; align-items: center; gap: 9px; padding: 5px 9px 5px 14px; border: 0; border-left: 1px solid var(--line); border-radius: 0 10px 10px 0; background: transparent; transition: background .15s ease; }
.topbar-user:hover { background: var(--line-soft); }
.topbar-user .avatar { flex: 0 0 29px; width: 29px; height: 29px; border-radius: 8px; }
.topbar-user-text { text-align: left; }
.topbar-user strong { display: block; color: var(--ink); font-size: 11.5px; font-weight: 600; }
.topbar-user span { display: block; margin-top: 1px; color: var(--ink-faint); font-size: 9.5px; }
.topbar-user-chevron { width: 14px; height: 14px; color: var(--ink-faint); transition: transform .15s ease; }
.topbar-user[aria-expanded="true"] .topbar-user-chevron { transform: rotate(180deg); }

.user-menu { position: absolute; top: calc(100% + 10px); right: 0; z-index: 30; width: 260px; padding: 6px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); box-shadow: var(--shadow-lift); }
.user-menu[hidden] { display: none; }
.user-menu-head { display: flex; align-items: center; gap: 11px; padding: 10px 10px 12px; }
.user-menu-head .avatar { flex: 0 0 38px; width: 38px; height: 38px; border-radius: 10px; font-size: 13px; }
.user-menu-id { min-width: 0; }
.user-menu-id strong { display: block; color: var(--ink); font-size: 13px; font-weight: 600; }
.user-menu-id > span { display: block; overflow: hidden; color: var(--ink-faint); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.user-menu-role { display: inline-block; margin-top: 6px; padding: 2px 8px; border-radius: 999px; color: #fff; background: var(--dark-ink); font-size: 9px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; }
.role-pill { display: inline-flex; padding: 2px 8px; border-radius: 999px; color: #fff; background: var(--dark-ink); font-size: 9px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; }
.user-menu-list { border-top: 1px solid var(--line); padding-top: 6px; }
.user-menu-item { display: flex; align-items: center; gap: 11px; width: 100%; padding: 9px 10px; border: 0; border-radius: 9px; color: var(--ink-soft); background: transparent; font-size: 13px; font-weight: 500; text-align: left; }
.user-menu-item svg { flex: 0 0 17px; width: 17px; height: 17px; color: var(--ink-faint); }
.user-menu-item:hover { color: var(--ink); background: var(--line-soft); }
.user-menu-item:hover svg { color: var(--ink-soft); }
.user-menu-divider { height: 1px; margin: 6px 4px; background: var(--line); }
.user-menu-item.is-danger { color: var(--danger); }
.user-menu-item.is-danger svg { color: var(--danger); }
.user-menu-item.is-danger:hover { background: var(--danger-pale); }
.notification-button { position: relative; display: grid; place-items: center; width: 36px; height: 36px; color: var(--ink-soft); border-radius: var(--radius-sm); transition: background .15s var(--ease), color .15s var(--ease); }
.notification-button svg { width: 18px; height: 18px; }
.notification-button:hover { color: var(--brand-700); background: var(--brand-50); }
.notification-badge { position: absolute; top: 2px; right: 3px; display: grid; place-items: center; min-width: 14px; height: 14px; padding: 0 3px; border-radius: 999px; color: #fff; background: var(--danger); box-shadow: 0 0 0 2px #fff; font-size: 8px; font-weight: 700; }
.outline-button { display: inline-flex; align-items: center; gap: 9px; border: 1px solid var(--line); border-radius: 8px; color: var(--ink); background: var(--surface); box-shadow: var(--shadow-soft); font-size: 12px; font-weight: 500; }
.search-button { display: inline-flex; align-items: center; gap: 9px; width: 220px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px; color: var(--ink-faint); background: var(--paper); font-size: 12.5px; font-weight: 500; text-align: left; transition: border-color .15s ease; }
.search-button:hover { border-color: var(--ink-faint); background: var(--surface); }
.search-button svg { flex: 0 0 15px; width: 15px; height: 15px; color: var(--ink-faint); }
.search-button kbd { margin-left: auto; }
kbd { padding: 2px 5px; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 4px; color: var(--ink-faint); background: var(--line-soft); font-size: 9px; }
.content-wrap { width: min(1220px, 100%); margin: 0 auto; padding: 30px 46px 24px; }
.page-heading { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 22px; }
h1, h2, h3, p { margin: 0; }
h1 { max-width: 650px; margin-top: 2px; color: var(--ink); font-weight: 700; font-size: clamp(22px, 2.5vw, 27px); letter-spacing: -.02em; line-height: 1.15; }
.page-heading p { margin-top: 6px; color: var(--ink-soft); font-size: 13px; }
.page-heading-actions { display: flex; flex: 0 0 auto; align-items: center; gap: 10px; }
.page-heading-actions:empty { display: none; }
.outline-button { padding: 10px 14px; color: var(--ink); background: var(--surface); }
.outline-button:hover, .search-button:hover { border-color: var(--ink-faint); background: var(--line-soft); }
.outline-button span { color: var(--ink); font-size: 15px; }
.section-kicker { display: flex; align-items: center; gap: 7px; color: var(--dark-ink-soft); font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.spark { font-size: 13px; }
.live-pill { padding: 3px 7px; border-radius: 999px; color: #fff; background: rgba(255, 255, 255, .18); font-size: 8px; font-weight: 700; letter-spacing: .06em; }
.loading-line { color: var(--ink-faint) !important; }
.meta-separator { color: rgba(255, 255, 255, .3); }
/* Dashboard — slim AI summary banner */
.ai-summary-banner { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; padding: 14px 18px; border: 1px solid var(--accent-violet-line); border-radius: var(--radius-md); background: var(--accent-violet-pale); }
.ai-summary-ic { display: grid; place-items: center; flex: 0 0 34px; width: 34px; height: 34px; border-radius: var(--radius-sm); color: #fff; background: var(--accent-violet); }
.ai-summary-ic svg { width: 16px; height: 16px; }
.ai-summary-copy { min-width: 0; flex: 1; display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px; }
.ai-summary-copy strong { color: var(--ink); font-size: 13px; font-weight: 700; white-space: nowrap; }
.ai-summary-copy span { color: var(--ink-soft); font-size: 12.5px; line-height: 1.4; }
.ai-summary-cta { flex: 0 0 auto; padding: 8px 16px; border: 1px solid var(--accent-violet-line); border-radius: 999px; color: var(--accent-violet); background: var(--surface); font-size: 12.5px; font-weight: 700; white-space: nowrap; transition: background .15s var(--ease); }
.ai-summary-cta:hover { background: var(--accent-violet-pale); }
/* Dashboard — two-column main grid: priority list + agenda/tasks rail */
.dash-main-grid { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 16px; margin-bottom: 16px; align-items: start; }
.dash-side-col { display: flex; flex-direction: column; gap: 16px; }
@media (max-width: 1150px) { .dash-main-grid { grid-template-columns: 1fr; } }
.panel-count { display: inline-flex; align-items: center; justify-content: center; min-width: 19px; height: 19px; padding: 0 6px; border-radius: 999px; color: var(--brand-700); background: var(--brand-100); font-size: 11px; font-weight: 700; }
.today-panel-list { display: flex; flex-direction: column; gap: 9px; }
.today-panel-row { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 52px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); transition: border-color .15s ease, box-shadow .15s ease; }
.today-panel-row:hover { border-color: var(--brand-200); box-shadow: var(--shadow-soft); }
.today-panel-kind { display: grid; flex: 0 0 30px; place-items: center; width: 30px; height: 30px; border-radius: 9px; color: var(--ink-soft); background: var(--line-soft); }
.today-panel-kind svg { width: 15px; height: 15px; }
.today-panel-kind--danger { color: var(--danger); background: var(--danger-pale); }
.today-panel-kind--warn { color: var(--warn); background: var(--warn-pale); }
.today-panel-kind--brand { color: var(--brand-700); background: var(--brand-100); }
.today-panel-main { min-width: 0; flex: 1; }
.today-panel-main strong { display: block; overflow: hidden; color: var(--ink); font-size: 13px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.today-panel-main span { display: block; margin-top: 2px; overflow: hidden; color: var(--ink-soft); font-size: 11.5px; text-overflow: ellipsis; white-space: nowrap; }
.today-panel-assignee { display: flex; flex: 0 0 auto; align-items: center; gap: 8px; min-width: 0; max-width: 130px; color: var(--ink-soft); font-size: 12px; font-weight: 500; }
.today-panel-assignee span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.today-panel-action { flex: 0 0 auto; padding: 7px 12px; border: 1px solid var(--line); border-radius: 8px; color: var(--ink-soft); background: var(--paper); font-size: 11.5px; font-weight: 600; white-space: nowrap; }
.today-panel-action:hover { border-color: var(--brand-400, var(--brand-600)); color: var(--ink); }
@media (max-width: 720px) { .today-panel-assignee { display: none; } }
/* Dashboard — agenda timeline (legacy rows, still used by agenda-day-list) */
.agenda-timeline { display: flex; flex-direction: column; }
.agenda-item { position: relative; display: flex; gap: 12px; padding-bottom: 16px; }
.agenda-item:last-child { padding-bottom: 0; }
.agenda-item::before { content: ""; position: absolute; left: 3px; top: 16px; bottom: 0; width: 1px; background: var(--line); }
.agenda-item:last-child::before { display: none; }
.agenda-dot { flex: 0 0 8px; width: 8px; height: 8px; margin-top: 4px; border-radius: 50%; background: var(--brand-600); z-index: 1; }
.agenda-item--done .agenda-dot { background: var(--line); }
.agenda-time { flex: 0 0 42px; color: var(--ink-faint); font-size: 11px; font-weight: 600; font-variant-numeric: tabular-nums; }
.agenda-body { min-width: 0; }
.agenda-body strong { display: block; color: var(--ink); font-size: 12.5px; font-weight: 600; line-height: 1.3; }
.agenda-body span { display: block; margin-top: 2px; color: var(--ink-faint); font-size: 11px; }

/* Dashboard — Agenda do Dia + Orçamento Federal secondary row */
.dash-secondary-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 420px); gap: 16px; margin-bottom: 16px; align-items: start; }
/* Gráfico de evolução + distribuição por categoria, lado a lado. */
.dash-chart-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 360px); gap: 16px; margin-bottom: 16px; align-items: start; }
@media (max-width: 1150px) { .dash-chart-grid { grid-template-columns: 1fr; } }
.panel-subtitle { margin: -10px 0 16px; color: var(--ink-faint); font-size: 12px; }
.monthly-volume-chart { display: block; width: 100%; height: auto; }
.monthly-volume-area { fill: var(--brand-50); }
.monthly-volume-line { fill: none; stroke: var(--brand-600); stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.monthly-volume-grid { stroke: var(--line); stroke-width: 1; }
.monthly-volume-label { fill: var(--ink-faint); font-size: 10px; }
@media (max-width: 1150px) { .dash-secondary-grid { grid-template-columns: 1fr; } }
.agenda-day-month { margin: -6px 0 10px; color: var(--ink-faint); font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }
.agenda-week-strip { display: flex; align-items: center; gap: 4px; margin-bottom: 14px; }
.agenda-week-nav { display: grid; flex: 0 0 24px; place-items: center; width: 24px; height: 24px; border: 1px solid var(--line); border-radius: 7px; color: var(--ink-soft); background: var(--surface); font-size: 14px; line-height: 1; }
.agenda-week-nav:hover { border-color: var(--brand-400, var(--brand-600)); color: var(--ink); }
.agenda-week-days { display: grid; flex: 1; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.agenda-week-day { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 2px; border: 1px solid transparent; border-radius: 9px; color: var(--ink-soft); background: transparent; font-size: 10px; font-weight: 600; text-transform: uppercase; }
.agenda-week-day strong { font-size: 13px; font-weight: 700; color: var(--ink); }
.agenda-week-day:hover { background: var(--paper); }
.agenda-week-day.is-selected { border-color: var(--brand-600); background: var(--brand-600); color: #fff; }
.agenda-week-day.is-selected strong { color: #fff; }
.agenda-day-list { display: flex; flex-direction: column; gap: 9px; max-height: 420px; overflow-y: auto; }
.agenda-day-row { position: relative; display: flex; align-items: flex-start; gap: 12px; padding: 12px 14px 12px 16px; border: 1px solid var(--line); border-left: 3px solid var(--brand-600); border-radius: 12px; background: var(--surface); }
.agenda-day-row--brand { border-left-color: var(--brand-600); }
.agenda-day-row--neutral { border-left-color: var(--ink-faint); }
.agenda-day-row--warn { border-left-color: var(--warn); }
.agenda-day-row--ok { border-left-color: var(--ok); }
.agenda-day-row--done { border-left-color: var(--ok); opacity: .72; }
.agenda-day-row--canceled { border-left-color: var(--danger); opacity: .72; }
.agenda-day-row--canceled .agenda-day-row-main strong { text-decoration: line-through; }
.agenda-day-row-main { min-width: 0; flex: 1; }
.agenda-day-row-main strong { display: block; color: var(--ink); font-size: 13px; font-weight: 600; }
.agenda-day-row-meta { margin-top: 2px; color: var(--ink-soft); font-size: 11.5px; }
.agenda-day-row-meta .badge { margin-left: 6px; }
.agenda-day-row-desc { margin-top: 4px; color: var(--ink-faint); font-size: 11.5px; }
.agenda-day-row-status { flex: 0 0 auto; }

/* Dashboard — Orçamento Federal card */
.orcamento-list { display: flex; flex-direction: column; gap: 10px; }
.orcamento-row { position: relative; display: flex; align-items: center; gap: 10px; padding: 13px 12px 11px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); overflow: hidden; }
.orcamento-row::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 3px; background: linear-gradient(90deg, var(--brand-600), var(--mint)); }
.orcamento-row-ic { display: grid; flex: 0 0 28px; place-items: center; width: 28px; height: 28px; border-radius: 8px; color: var(--brand-700); background: var(--brand-100); }
.orcamento-row-ic svg { width: 14px; height: 14px; }
.orcamento-row-main { min-width: 0; flex: 1; }
.orcamento-row-main strong { display: block; overflow: hidden; color: var(--ink); font-size: 12.5px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.orcamento-row-main span { display: block; margin-top: 1px; overflow: hidden; color: var(--ink-faint); font-size: 10.5px; text-overflow: ellipsis; white-space: nowrap; }
.orcamento-row-value { flex: 0 0 auto; text-align: right; }
.orcamento-row-value strong { display: block; color: var(--ok); font-size: 13.5px; font-weight: 700; font-variant-numeric: tabular-nums; }
.orcamento-row-value span { display: block; margin-top: 2px; color: var(--ink-faint); font-size: 9.5px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
/* Dashboard — my tasks checklist */
.task-checklist { display: flex; flex-direction: column; gap: 2px; }
.task-row { display: flex; align-items: center; gap: 10px; padding: 8px 2px; border-top: 1px solid var(--line-soft); }
.task-row:first-child { border-top: 0; }
.task-checkbox { display: grid; flex: 0 0 18px; place-items: center; width: 18px; height: 18px; border: 1.5px solid var(--line); border-radius: 5px; color: transparent; background: var(--surface); }
.task-checkbox:hover { border-color: var(--brand-400, var(--brand-600)); }
.task-checkbox svg { width: 11px; height: 11px; }
.task-row-label { min-width: 0; overflow: hidden; color: var(--ink); font-size: 12.5px; font-weight: 500; text-overflow: ellipsis; white-space: nowrap; }
.metric-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; margin-bottom: 44px; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; background: var(--line); box-shadow: var(--shadow-soft); }
.metric-item { min-height: 92px; padding: 18px 20px; background: var(--surface); }
.metric-item strong { display: block; margin-top: 8px; font-size: 27px; font-weight: 700; letter-spacing: -.02em; font-variant-numeric: tabular-nums; color: var(--ink); }
.metric-context { display: block; margin-top: 4px; color: var(--ink-faint); font-size: 10px; }
.warning-context { color: var(--warn); }
.support-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; }
.support-faq { border-bottom: 1px solid var(--line-soft); padding: 4px 0; }
.support-faq:last-child { border-bottom: 0; }
.support-faq summary { cursor: pointer; padding: 10px 0; color: var(--ink); font-size: 13.5px; font-weight: 600; list-style: none; }
.support-faq summary::-webkit-details-marker { display: none; }
.support-faq summary::before { content: "+"; display: inline-block; width: 16px; color: var(--ink-faint); font-weight: 700; }
.support-faq[open] summary::before { content: "–"; }
.support-faq p { margin: 0 0 10px 16px; color: var(--ink-soft); font-size: 12.5px; line-height: 1.5; }
.support-contact { display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }
.support-contact .btn-create { width: auto; }
@media (max-width: 1000px) { .support-grid { grid-template-columns: 1fr; } }
.birthday-strip { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; padding: 14px 20px; border: 1px solid var(--brand-100); border-radius: 16px; background: var(--brand-50); }
.birthday-ic { font-size: 22px; }
.birthday-text { flex: 1; min-width: 0; }
.birthday-text strong { display: block; color: var(--ink); font-size: 13.5px; }
.birthday-text span { color: var(--ink-soft); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: block; }
.btn-small { padding: 6px 12px; font-size: 12px; }
/* Demand detail drawer — docked to the right, leaving the list visible beside it. */
.demand-drawer { position: fixed; top: 68px; right: 0; bottom: 0; width: min(420px, 100%); z-index: 40; }
.demand-drawer-panel { position: relative; width: 100%; height: 100%; overflow-y: auto; padding: 28px 28px 32px; border-left: 1px solid var(--line); background: var(--surface); box-shadow: -16px 0 48px rgba(15, 23, 42, .12); animation: drawer-in .18s ease; }
body.drawer-open .main-content { padding-right: min(420px, 100%); }
@media (max-width: 900px) { body.drawer-open .main-content { padding-right: 0; } }
@keyframes drawer-in { from { transform: translateX(24px); opacity: .6; } to { transform: none; opacity: 1; } }
.demand-drawer-close { position: absolute; top: 20px; right: 20px; display: grid; place-items: center; width: 30px; height: 30px; border: 0; border-radius: 8px; color: var(--ink-soft); background: var(--line-soft); cursor: pointer; }
.demand-drawer-close:hover { color: var(--ink); background: var(--line); }
.demand-drawer-eyebrow { display: block; color: var(--ink); font-size: 16px; font-weight: 700; }
.demand-drawer-proto { display: block; margin-top: 2px; color: var(--ink-faint); font-size: 12px; font-variant-numeric: tabular-nums; }
.demand-drawer-badges { display: flex; gap: 8px; margin: 16px 0 10px; }
.demand-drawer-title { font-size: 21px; font-weight: 700; line-height: 1.25; color: var(--ink); }
.demand-drawer-loc, .demand-drawer-cat { display: flex; align-items: center; gap: 8px; margin-top: 10px; color: var(--ink-soft); font-size: 13px; }
.demand-drawer-loc svg, .demand-drawer-cat svg { width: 16px; height: 16px; flex: 0 0 16px; color: var(--ink-faint); }
.demand-drawer-sla { margin: 18px 0; padding: 14px 16px; border-radius: 12px; }
.demand-drawer-sla .demand-sla-label { display: flex; align-items: center; gap: 6px; font-size: 11px; font-weight: 600; }
.demand-drawer-sla strong { display: block; margin-top: 3px; font-size: 15px; }
.demand-drawer-sla.sla-warn { background: var(--warn-pale); color: var(--warn); }
.demand-drawer-sla.sla-danger { background: var(--danger-pale); color: var(--danger); }
.demand-drawer-sla.sla-ok { background: var(--ok-pale); color: var(--ok); }
.demand-drawer-sla.sla-neutral { background: var(--line-soft); color: var(--ink-soft); }
.demand-drawer-people { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 18px 0; }
.demand-drawer-people span { display: block; color: var(--ink-faint); font-size: 11px; }
.demand-drawer-people strong { display: block; margin-top: 2px; color: var(--ink); font-size: 13px; }
.demand-drawer-desc span, .demand-drawer-history > span, .demand-drawer-attach > span { display: block; color: var(--ink-faint); font-size: 11px; font-weight: 600; margin-bottom: 6px; }
.demand-drawer-attach { margin-bottom: 18px; }
.demand-attach-grid { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.demand-attach-empty { color: var(--ink-faint); font-size: 12px; }
.demand-attach-thumb { width: 72px; height: 72px; padding: 0; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; cursor: pointer; background: var(--line-soft); }
.demand-attach-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.image-viewer { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 32px; background: rgba(15, 23, 42, .8); cursor: zoom-out; }
.image-viewer img { max-width: 100%; max-height: 100%; border-radius: 12px; box-shadow: 0 20px 60px rgba(0, 0, 0, .4); }
.demand-drawer-desc p { margin: 0 0 18px; color: var(--ink); font-size: 13px; line-height: 1.5; }
.demand-timeline { list-style: none; margin: 6px 0 20px; padding: 0; }
.demand-timeline li { position: relative; display: flex; gap: 12px; padding-bottom: 14px; }
.demand-timeline li::before { content: ""; position: absolute; left: 4px; top: 14px; bottom: 0; width: 2px; background: var(--line); }
.demand-timeline li.is-last::before { display: none; }
.demand-dot { flex: 0 0 10px; width: 10px; height: 10px; margin-top: 2px; border-radius: 50%; background: var(--brand-600); z-index: 1; }
.demand-timeline li:not(:first-child) .demand-dot { background: var(--line); }
.demand-timeline strong { display: block; color: var(--ink); font-size: 12.5px; }
.demand-timeline span { color: var(--ink-faint); font-size: 11px; }
.demand-drawer-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 8px; }
.demand-drawer-actions button { justify-content: center; }
.demand-drawer-actions button:first-child { flex: 1 1 100%; }
.demand-drawer-actions button:not(:first-child) { flex: 1 1 140px; }
@media (max-width: 520px) { .demand-drawer-panel { max-width: 100%; } }
.panel-live { display: inline-flex; align-items: center; gap: 6px; margin-left: auto; color: var(--ink-faint); font-size: 10.5px; font-weight: 600; }
.live-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 0 rgba(5, 150, 105, .45); animation: live-pulse 2s infinite; }
@keyframes live-pulse { 0% { box-shadow: 0 0 0 0 rgba(5, 150, 105, .45); } 70% { box-shadow: 0 0 0 6px rgba(5, 150, 105, 0); } 100% { box-shadow: 0 0 0 0 rgba(5, 150, 105, 0); } }
/* Report stat tiles */
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-bottom: 32px; }
/* Card de métrica: rótulo + ícone simples no topo, número grande abaixo, sem chip colorido. */
.stat-tile { position: relative; display: block; width: 100%; padding: 18px 20px 16px; border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--surface); box-shadow: none; text-align: left; transition: box-shadow .15s var(--ease), transform .15s var(--ease); }
.stat-tile:hover { box-shadow: var(--shadow-soft); transform: translateY(-1px); }
.stat-ic { position: absolute; top: 16px; right: 16px; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; color: var(--brand-700); background: var(--brand-50); }
.stat-ic svg { width: 17px; height: 17px; }
.stat-body { min-width: 0; padding-right: 44px; }
.stat-trend-up { color: var(--ok); font-weight: 700; }
.stat-trend-down { color: var(--danger); font-weight: 700; }
.stat-label { display: block; color: var(--ink-faint); font-size: 10.5px; font-weight: 600; letter-spacing: .03em; text-transform: uppercase; }
.stat-tile strong { display: block; margin-top: 8px; font-size: 30px; font-weight: 700; letter-spacing: -.02em; font-variant-numeric: tabular-nums; color: var(--ink); line-height: 1.15; }
.stat-ctx { display: block; margin-top: 4px; color: var(--ink-faint); font-size: 10.5px; }
.stat-tile--brand .stat-ic { color: var(--ok); }
.stat-tile--warn .stat-ic { color: var(--warn); }
.stat-tile--warn strong { color: var(--warn); }
.stat-tile--danger .stat-ic { color: var(--danger); }
.stat-tile--danger strong { color: var(--danger); }
.stat-tile--ok .stat-ic { color: var(--ok); }
@media (max-width: 1100px) { .stat-grid { grid-template-columns: repeat(2, 1fr); } }

.section-note { color: var(--ink-faint); font-size: 10px; }
.section-note--tight { margin: -8px 0 16px; }
.chart-body { padding: 18px 20px; }
/* Donut */
.donut-wrap { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }
.donut { width: 140px; height: 140px; flex: 0 0 140px; }
.donut-total { text-anchor: middle; font-size: 24px; font-weight: 700; fill: var(--ink); }
/* Rótulo longo, como "722 mil", precisa de corpo menor para caber dentro do anel. */
.donut-total--longo { font-size: 19px; }
.donut-cap { text-anchor: middle; font-size: 9px; letter-spacing: .1em; text-transform: uppercase; fill: var(--ink-faint); }
.chart-legend { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; flex: 1; min-width: 140px; }
.chart-legend li { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--ink-soft); }
.chart-legend .legend-label { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chart-legend strong { color: var(--ink); font-size: 12px; }
.chart-legend em { color: var(--ink-faint); font-size: 11px; font-style: normal; min-width: 34px; text-align: right; }
.legend-dot { flex: 0 0 10px; width: 10px; height: 10px; border-radius: 3px; }
/* Vertical bars */
.vbar-chart { display: flex; align-items: flex-end; gap: 10px; height: 180px; padding-top: 10px; }
.vbar-col { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 6px; height: 100%; }
.vbar-value { font-size: 11px; font-weight: 700; color: var(--ink); }
.vbar { width: 70%; max-width: 38px; border-radius: 6px 6px 2px 2px; min-height: 4px; }
.vbar-label { font-size: 9.5px; color: var(--ink-faint); text-align: center; line-height: 1.25; max-width: 100%; word-break: break-word; }
/* SLA stacked bar */
.sla-bar { display: flex; height: 22px; border-radius: 8px; overflow: hidden; background: var(--line-soft); }
.sla-seg { height: 100%; }
.sla-legend { list-style: none; margin: 14px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 18px; }
.sla-legend li { display: flex; align-items: center; gap: 7px; font-size: 12px; color: var(--ink-soft); }
.sla-legend strong { color: var(--ink); }
/* Productivity stacked rows */
.prod-row { display: grid; grid-template-columns: 150px 1fr; align-items: center; gap: 12px; padding: 7px 0; }
.prod-name strong { display: block; font-size: 12.5px; color: var(--ink); }
.prod-name span { font-size: 10.5px; color: var(--ink-faint); }
.prod-track { display: flex; height: 14px; border-radius: 7px; overflow: hidden; background: var(--line-soft); }
.prod-seg { height: 100%; }
.prod-resolved { background: #059669; }
.prod-open { background: #e8902f; }
/* Emerging trends */
.trends-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; padding: 16px 20px; }
.trend-card { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 12px 14px; border: 1px solid var(--line-soft); border-left: 3px solid var(--warn); border-radius: 12px; background: var(--surface); cursor: pointer; transition: box-shadow .12s ease, border-color .12s ease; }
.trend-card:hover { border-color: var(--line); box-shadow: 0 2px 10px rgba(15, 23, 42, .07); }
.trend-spark { display: grid; place-items: center; flex: 0 0 34px; width: 34px; height: 34px; border-radius: 9px; color: var(--warn); background: var(--warn-pale); }
.trend-spark svg { width: 18px; height: 18px; }
.trend-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.trend-main strong { color: var(--ink); font-size: 13px; font-weight: 600; }
.trend-where { color: var(--ink-soft); font-size: 11.5px; }
.trend-compare { color: var(--ink-faint); font-size: 10.5px; }
.trend-compare b { color: var(--ink); }
.trend-delta { flex: 0 0 auto; display: flex; flex-direction: column; align-items: flex-end; color: var(--warn); font-size: 15px; font-weight: 700; }
.trend-delta em { color: var(--ink-faint); font-size: 10px; font-style: normal; font-weight: 600; }
.insights-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-bottom: 16px; }
.insights-grid-secondary { grid-template-columns: repeat(2, 1fr); margin-bottom: 0; }
.insights-grid--four { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 1150px) { .insights-grid--four { grid-template-columns: repeat(2, 1fr); } }
.panel { min-height: 190px; padding: 20px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); box-shadow: none; }
.panel-heading { display: flex; align-items: center; gap: 10px; margin: -20px -20px 18px; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.panel-heading > svg:first-child { box-sizing: border-box; flex: 0 0 30px; width: 30px; height: 30px; padding: 7px; border-radius: 9px; color: var(--brand-600); background: var(--brand-50); }
.panel-heading svg { width: 16px; height: 16px; color: var(--ink-faint); flex: 0 0 16px; }
.panel h3 { font-size: 15px; font-weight: 600; letter-spacing: -.01em; color: var(--ink); }
.panel-heading .panel-link { margin-left: auto; }
.compact-empty { min-height: 140px; align-items: center; justify-content: center; text-align: center; }
.compact-empty p { max-width: 280px; }
.chart-body > .empty-state { align-items: center; text-align: center; width: 100%; }
.empty-state { display: flex; flex-direction: column; justify-content: center; align-items: flex-start; color: var(--ink-soft); }
.empty-glyph { display: block; margin-bottom: 10px; color: var(--ink-faint); font-size: 23px; }
.empty-glyph svg { width: 26px; height: 26px; }
.empty-state strong { color: var(--ink); font-size: 12px; font-weight: 600; }
.empty-state p { max-width: 240px; margin-top: 6px; color: var(--ink-faint); font-size: 11px; line-height: 1.45; }
.empty-state-lg { padding: 48px 20px; }
.panel-link { display: inline-flex; flex: none; align-items: center; gap: 7px; border: 0; color: var(--ink-soft); background: transparent; font-size: 11px; font-weight: 700; padding: 0; white-space: nowrap; }
.panel-link svg { width: 12px; height: 12px; }
.panel-link:hover { color: var(--ink); }
.workload-row { display: grid; grid-template-columns: 1fr 45px; gap: 14px; align-items: center; margin-bottom: 17px; }
.workload-label { display: flex; justify-content: space-between; margin-bottom: 6px; color: var(--ink-soft); font-size: 10px; }
.workload-label strong { color: var(--ink); font-weight: 600; }
.bar-track { height: 5px; overflow: hidden; border-radius: 999px; background: var(--line-soft); }
.bar-fill { height: 100%; border-radius: inherit; background: var(--dark-ink); }
.workload-number { color: var(--ink); font-size: 16px; font-weight: 600; font-variant-numeric: tabular-nums; text-align: right; }
/* Dashboard bairro/equipe bars — compact single-row layout (name | bar | count) */
.dash-bar-row { display: grid; grid-template-columns: 112px 1fr 24px; align-items: center; gap: 14px; margin-bottom: 19px; }
.dash-bar-row:last-child { margin-bottom: 0; }
.dash-bar-name { overflow: hidden; color: var(--ink); font-size: 13px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.dash-bar-count { color: var(--ink); font-size: 13px; font-weight: 600; font-variant-numeric: tabular-nums; text-align: right; }

.modal-backdrop { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 20px; background: rgba(15, 23, 42, .5); }
.modal-backdrop[hidden] { display: none; }
.ask-modal { width: min(550px, 100%); padding: 25px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); box-shadow: var(--shadow-lift); }
.modal-topline { display: flex; justify-content: space-between; align-items: center; }
.close-button { width: 28px; height: 28px; border-radius: 50%; color: var(--ink-faint); background: var(--line-soft); font-size: 20px; line-height: 1; }
.close-button:hover { color: var(--ink); background: var(--line); }
.ask-modal h2 { margin-top: 20px; font-size: 24px; font-weight: 700; letter-spacing: -.01em; color: var(--ink); }
.modal-description { margin-top: 7px; color: var(--ink-soft); font-size: 12px; line-height: 1.5; }
.ask-form { margin-top: 22px; } .ask-form label { display: block; margin-bottom: 7px; color: var(--ink-faint); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; }
.ask-input-wrap { display: flex; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.ask-input-wrap:focus-within { border-color: var(--dark-ink); box-shadow: 0 0 0 3px rgba(23, 125, 98, .18); }
.ask-input-wrap input { min-width: 0; flex: 1; padding: 12px; border: 0; outline: 0; color: var(--ink); background: transparent; font-size: 12px; }
.ask-input-wrap button { width: 42px; margin: 4px; border: 0; border-radius: 6px; color: #fff; background: var(--dark-ink); font-size: 17px; }
.ask-input-wrap button:hover { background: var(--brand-900); }
.suggestion { padding: 6px 9px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink-soft); background: transparent; font-size: 10px; }
.suggestion:hover { border-color: var(--line); color: var(--ink); background: var(--line-soft); }
.email-provider-logos { display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0 4px; }
.email-provider-chip { display: inline-flex; align-items: center; gap: 7px; padding: 5px 11px 5px 6px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink-soft); font-size: 11.5px; font-weight: 600; }
.email-provider-chip .email-provider-icon { flex: 0 0 22px; width: 22px; height: 22px; border-radius: 6px; }
.email-provider-chip .email-provider-icon svg { width: 12px; height: 12px; }
.email-provider-chip .email-provider-icon.logo img { width: 15px; height: 15px; }
.email-connect-step { margin-top: 18px; padding: 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); }
.email-connect-step > strong { color: var(--ink); font-size: 13px; }
.email-connect-step p { margin-top: 6px; color: var(--ink-soft); font-size: 12.5px; line-height: 1.5; }
.email-endpoint { display: flex; align-items: center; gap: 8px; margin-top: 10px; }
.email-endpoint code { flex: 1; min-width: 0; overflow: hidden; padding: 9px 11px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--ink); font-size: 11.5px; text-overflow: ellipsis; white-space: nowrap; }
.email-connect-note { color: var(--ink-faint) !important; font-size: 11.5px !important; }
.email-connect-actions { display: flex; justify-content: flex-end; margin-top: 18px; }
.email-provider-list { display: flex; flex-direction: column; gap: 10px; margin-top: 20px; }
.email-provider-row { display: flex; align-items: center; gap: 12px; padding: 12px; border: 1px solid var(--line); border-radius: 12px; }
.email-provider-icon { display: grid; flex: 0 0 34px; place-items: center; width: 34px; height: 34px; border-radius: 9px; color: #fff; }
.email-provider-icon svg { width: 16px; height: 16px; }
.email-provider-icon.logo { background: var(--line-soft); }
.email-provider-icon.logo img { width: 22px; height: 22px; object-fit: contain; border-radius: 5px; }
.email-provider-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.email-provider-body strong { font-size: 12.5px; font-weight: 600; color: var(--ink); }
.email-provider-body span { color: var(--ink-faint); font-size: 11px; }
.search-results { max-height: 340px; margin-top: 16px; overflow-y: auto; }
.search-results .empty-state { padding: 28px 4px; }
.search-result-item { display: flex; align-items: center; gap: 12px; width: 100%; padding: 11px 10px; border: 0; border-radius: 8px; background: transparent; text-align: left; }
.search-result-item:hover, .search-result-item:focus-visible { background: var(--line-soft); }
.search-result-kind { flex: 0 0 auto; padding: 3px 8px; border-radius: 999px; color: var(--brand-700); background: var(--brand-50); font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; white-space: nowrap; }
.search-result-text { min-width: 0; }
.search-result-text strong { display: block; overflow: hidden; color: var(--ink); font-size: 13px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.search-result-text span { display: block; overflow: hidden; margin-top: 2px; color: var(--ink-faint); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.toast { position: fixed; right: 24px; bottom: 24px; z-index: 120; max-width: 320px; padding: 11px 14px; border: 1px solid var(--line); border-radius: var(--radius-md); color: var(--ink); background: var(--surface); box-shadow: var(--shadow-lift); font-size: 11px; opacity: 0; transform: translateY(8px); pointer-events: none; transition: opacity .2s var(--ease), transform .2s var(--ease); }
.toast.is-visible { opacity: 1; transform: translateY(0); }

/* List views (Inbox, Demandas, Território, Meu trabalho, Incidentes, Automações, Relatórios) */
/* Pílula só com texto, sem bolinha — lida como etiqueta plana, não chip de alerta. */
.badge { display: inline-flex; align-items: center; border-radius: 999px; border: 1px solid; padding: 3px 11px; color: var(--ink-soft); background: transparent; font-size: 11px; font-weight: 600; text-transform: none; letter-spacing: 0; white-space: nowrap; }
.badge-brand { border-color: var(--line); color: var(--ink); background: var(--line-soft); }
.badge-solid { border-color: var(--dark-ink); color: #fff; background: var(--dark-ink); }
.badge-neutral { border-color: var(--line); color: var(--ink-soft); background: var(--line-soft); }
.badge-outline { border-color: var(--line); color: var(--ink-soft); background: transparent; }
.badge-ok { border-color: var(--ok-line); color: var(--ok); background: var(--ok-pale); }
.badge-warn { border-color: var(--warn-line); color: var(--warn); background: var(--warn-pale); }
.badge-danger { border-color: var(--danger-line); color: var(--danger); background: var(--danger-pale); }

.list-view { display: flex; flex-direction: column; gap: 18px; }
/* Card totalmente plano — só borda, sem sombra nem barra colorida no topo. */
.table-card { position: relative; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); box-shadow: none; overflow: hidden; }
.table-card-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 24px 26px 22px; border-bottom: 1px solid var(--line); }
.table-card-head-actions { display: flex; align-items: center; gap: 10px; }
.contact-tag { display: inline-block; padding: 2px 9px; margin: 0 2px 2px 0; border-radius: 999px; font-size: 11px; font-weight: 600; background: var(--brand-50); color: var(--brand-700); }
.productivity-empty { padding: 20px; text-align: center; color: var(--ink-faint); font-size: 12.5px; }
.doc-hash { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 10.5px; color: var(--ink-faint); }
.citizen-thread { display: flex; flex-direction: column; gap: 8px; max-height: 260px; overflow-y: auto; padding: 4px 2px; }
.citizen-thread-empty { color: var(--ink-faint); font-size: 12px; }
.citizen-msg { padding: 8px 10px; border-radius: 10px; max-width: 92%; }
.citizen-msg.is-in { align-self: flex-start; background: var(--line-soft, #eef1f6); }
.citizen-msg.is-out { align-self: flex-end; background: var(--brand-50); }
.citizen-msg-meta { display: flex; align-items: center; gap: 5px; margin-bottom: 3px; color: var(--ink-faint); font-size: 10px; }
.citizen-msg-body { color: var(--ink); font-size: 12.5px; line-height: 1.4; white-space: pre-wrap; word-break: break-word; }
.document-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; padding: 20px; }
.document-card { display: flex; flex-direction: column; gap: 8px; text-align: left; cursor: pointer; transition: border-color .15s ease, box-shadow .15s ease; }
.document-card:hover { border-color: var(--brand-400, var(--brand-600)); box-shadow: var(--shadow-soft); }
.document-card-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.document-card-top time { color: var(--ink-faint); font-size: 10.5px; }
.document-card strong { font-size: 13.5px; line-height: 1.35; }
.document-card-meta { color: var(--ink-faint); font-size: 11px; }
.doc-content { margin: 0; padding: 16px; max-height: 420px; overflow: auto; white-space: pre-wrap; word-break: break-word; font-family: "Lora", Georgia, serif; font-size: 13px; line-height: 1.6; color: var(--ink); background: var(--paper); border: 1px solid var(--line); border-radius: 10px; }
.table-card-head h3 { font-size: 17px; font-weight: 700; letter-spacing: -.015em; color: var(--ink); }
.table-card-head p { margin-top: 3px; color: var(--ink-soft); font-size: 12px; }
.table-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; padding: 16px 24px; border-bottom: 1px solid var(--line); background: var(--paper); }
.filter-select { height: 34px; padding: 0 10px; border: 1px solid var(--line); border-radius: var(--radius-sm); color: var(--ink-soft); background: var(--surface); font-size: 12px; font-weight: 500; transition: border-color .15s var(--ease); }
.filter-select:focus { outline: none; border-color: var(--dark-ink); box-shadow: 0 0 0 3px rgba(23, 125, 98, .18); }
.clear-filters-btn { margin-left: auto; }
.table-scroll { overflow-x: auto; }
/* min-width força o scroll horizontal em vez de espremer colunas (título quebrando em escada, responsável cortado). */
table.data-table { width: 100%; min-width: 760px; border-collapse: collapse; font-size: 13px; }
.data-table .primary-cell { white-space: nowrap; overflow: hidden; max-width: 280px; text-overflow: ellipsis; }
.data-table thead { background: var(--surface); border-bottom: 1px solid var(--line); }
.data-table th { height: 46px; padding: 0 18px; text-align: left; color: var(--ink-faint); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; white-space: nowrap; }
.data-table td { padding: 16px 18px; color: var(--ink-soft); font-variant-numeric: tabular-nums; border-bottom: 1px solid var(--line-soft); vertical-align: top; transition: background .12s var(--ease); }
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table tbody tr:hover td { background: var(--line-soft); }
.data-table tbody tr.is-clickable { cursor: pointer; }
.data-table .primary-cell { color: var(--ink); font-weight: 600; }
.cell-assignee { display: inline-flex; align-items: center; gap: 8px; min-width: 0; color: var(--ink-soft); font-size: 12.5px; font-weight: 500; white-space: nowrap; }
.cell-assignee .inbox-row-avatar { flex: 0 0 26px; width: 26px; height: 26px; font-size: 10px; }
.money-cell { display: block; text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.data-table td:has(> .money-cell) { text-align: right; }
.data-table thead th.money-head { text-align: right; }
.data-table .muted-cell { color: var(--ink-faint); font-size: 11px; margin-top: 2px; }
.table-pager { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 24px; border-top: 1px solid var(--line); color: var(--ink-faint); font-size: 11px; }
.table-pager .pager-buttons { display: flex; gap: 8px; }
.pager-button { padding: 7px 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); color: var(--ink-soft); background: var(--surface); font-size: 11px; font-weight: 600; transition: border-color .15s var(--ease), background .15s var(--ease); }
.pager-button:hover:not(:disabled) { border-color: var(--ink-faint); background: var(--paper); }
.pager-button:disabled { color: var(--line); cursor: not-allowed; }
.table-card-head--end { justify-content: flex-end; }
.amount-in { color: var(--ok); font-weight: 600; }
.amount-out { color: var(--danger); font-weight: 600; }
.alert-create-form { display: flex; gap: 10px; }
.alert-create-form .field-input { flex: 1; }
.form-builder-row { display: grid; grid-template-columns: minmax(0, 1.4fr) 150px minmax(0, 1.2fr) auto auto; gap: 8px; align-items: center; margin-bottom: 8px; }
.form-builder-row .field-input:disabled { background: var(--paper); color: var(--ink-faint); }
.field-group label.form-builder-required { display: inline-flex; align-items: center; gap: 6px; margin: 0; color: var(--ink-soft); font-size: 12px; font-weight: 500; letter-spacing: 0; text-transform: none; white-space: nowrap; }
.form-builder-actions { display: flex; justify-content: space-between; gap: 10px; margin-top: 14px; }
.form-public-link { margin: 0 0 10px; color: var(--ink-soft); font-size: 12px; word-break: break-all; }
.form-paused-note { margin: 0 0 10px; color: var(--warn); font-size: 12px; }
@media (max-width: 900px) { .form-builder-row { grid-template-columns: 1fr; } }
.alert-match-list { display: flex; flex-direction: column; gap: 6px; margin: 0; padding: 0; list-style: none; font-size: 12.5px; color: var(--ink-soft); }
.alert-match-list li { padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; background: var(--paper); }
.alert-no-match { color: var(--ink-faint); font-size: 12px; }
.legwatch-list { display: flex; flex-direction: column; gap: 10px; margin: 0; padding: 0; list-style: none; }
.legwatch-list li { padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); }
.legwatch-item-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.legwatch-item-head a { color: var(--ink); text-decoration: none; font-size: 13px; }
.legwatch-item-head a:hover { text-decoration: underline; }
.legwatch-list p { margin-top: 5px; color: var(--ink-soft); font-size: 12.5px; line-height: 1.45; }
.legwatch-item-meta { display: block; margin-top: 6px; color: var(--ink-faint); font-size: 11px; }
.election-cargo-warn { margin-top: 4px; padding: 9px 12px; border: 1px solid var(--warn-line); border-radius: 9px; background: var(--warn-pale); color: var(--warn); font-weight: 600; }
.heatmap-form { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.heatmap-form .field-input, .heatmap-form .filter-select { flex: 1 1 130px; min-width: 0; }
.heatmap-form button { flex: 0 0 auto; }
.heatmap-wrap { position: relative; }
#heatmap-map { height: 460px; width: 100%; }
.heatmap-legend { position: absolute; right: 14px; bottom: 14px; z-index: 500; display: flex; align-items: center; gap: 8px; padding: 7px 11px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); color: var(--ink-soft); font-size: 10.5px; font-weight: 600; }
.heatmap-scale { display: block; width: 90px; height: 7px; border-radius: 999px; background: linear-gradient(90deg, #177D62, #eab308, #e8902f, #d0453b); }
.legwatch-warning { margin-bottom: 10px; padding: 9px 12px; border: 1px solid var(--warn-line); border-radius: 9px; background: var(--warn-pale); color: var(--warn); font-size: 12px; font-weight: 600; }

/* Demandas — alert banner, tabs, search, row checkboxes, bulk bar */
.demands-alert-banner { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; padding: 14px 18px; border: 1px solid var(--danger-line); border-radius: 14px; background: var(--danger-pale); }
.demands-alert-banner svg { flex: 0 0 20px; width: 20px; height: 20px; color: var(--danger); }
.demands-alert-banner strong { color: var(--danger); font-size: 13px; font-weight: 700; }
.demands-alert-banner span { margin-left: 4px; color: var(--ink-soft); font-size: 12.5px; }
.demands-tabs-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 20px; border-bottom: 1px solid var(--line); }
.demands-tabs { display: flex; gap: 8px; }
.demands-tab { display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px; border: 0; border-radius: 9px; color: var(--ink-soft); background: transparent; font-size: 13px; font-weight: 600; transition: background .15s ease, color .15s ease; }
.demands-tab:hover { color: var(--ink); background: var(--line-soft); }
.demands-tab.is-active { color: #fff; background: var(--brand-600); }
.demands-tab-count { padding: 1px 7px; border-radius: 999px; background: var(--line); color: var(--ink-soft); font-size: 10.5px; font-weight: 700; }
.demands-tab.is-active .demands-tab-count { background: rgba(255, 255, 255, .25); color: #fff; }
.demands-search-wrap { position: relative; flex: 1; min-width: 200px; }
.demands-search-wrap svg { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); width: 14px; height: 14px; color: var(--ink-faint); }
.demands-search-wrap input { width: 100%; height: 34px; padding: 0 12px 0 32px; border: 1px solid var(--line); border-radius: var(--radius-sm); color: var(--ink); background: var(--surface); font-size: 12.5px; transition: border-color .15s var(--ease); }
.demands-search-wrap input:focus { outline: none; border-color: var(--dark-ink); box-shadow: 0 0 0 3px rgba(23, 125, 98, .18); }
#demands-export-btn svg, #demands-more-filters-btn svg { display: inline-block; width: 14px; height: 14px; vertical-align: -2px; margin-right: 2px; }
.demands-more-filters { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; padding: 0 20px 13px; color: var(--ink-soft); font-size: 12.5px; }
.demands-more-filters label { display: inline-flex; align-items: center; gap: 7px; }
.checkbox-cell { width: 34px; }
.row-checkbox { width: 15px; height: 15px; accent-color: var(--brand-600); cursor: pointer; }
.demand-row-kebab { width: 26px; height: 26px; border: 0; border-radius: 7px; color: var(--ink-faint); background: transparent; font-size: 16px; line-height: 1; cursor: pointer; }
.demand-row-kebab:hover { color: var(--ink); background: var(--line-soft); }
.demands-bulk-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 12px 20px; border-bottom: 1px solid var(--brand-100); background: var(--brand-50); }
.demands-bulk-bar strong { color: var(--brand-700); font-size: 12.5px; white-space: nowrap; }
.demands-tip-banner { display: flex; align-items: center; gap: 10px; margin-top: 16px; padding: 13px 18px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); color: var(--ink-soft); font-size: 12.5px; }
.demands-tip-banner svg { flex: 0 0 16px; width: 16px; height: 16px; color: var(--ink-faint); }

.entity-card { border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; background: var(--surface); box-shadow: var(--shadow-soft); }

/* Território — layout, map toggle/legend, inline detail panel */
.territory-layout { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 16px; align-items: start; }
.territory-main { min-width: 0; }
@media (max-width: 1150px) { .territory-layout { grid-template-columns: 1fr; } }
.territory-detail-panel { padding: 0; max-height: 820px; overflow-y: auto; }
.territory-detail-panel .panel-heading { margin: 0; }
.territory-detail-panel .demand-drawer-eyebrow, .territory-detail-panel .demand-drawer-proto, .territory-detail-panel .demand-drawer-badges, .territory-detail-panel .demand-drawer-title, .territory-detail-panel .demand-drawer-loc, .territory-detail-panel .demand-drawer-cat, .territory-detail-panel .demand-drawer-sla, .territory-detail-panel .demand-drawer-people, .territory-detail-panel .demand-drawer-desc, .territory-detail-panel .demand-drawer-attach, .territory-detail-panel .demand-drawer-history, .territory-detail-panel .demand-drawer-actions { margin-left: 20px; margin-right: 20px; }
.territory-detail-panel .demand-drawer-eyebrow { display: none; }
.territory-detail-panel .demand-drawer-proto { margin-top: 18px; }
.territory-detail-panel .demand-drawer-actions { margin-bottom: 20px; }
.territory-detail-panel #territory-detail-body > .empty-state { padding: 40px 20px; }
.territory-map-wrap { position: relative; margin: 0 20px 14px; border-radius: 14px; overflow: hidden; border: 1px solid var(--line); z-index: 0; }
.territory-map { height: 560px; }
.territory-tile-toggle { position: absolute; top: 12px; right: 12px; z-index: 500; display: inline-flex; gap: 2px; padding: 3px; border-radius: 10px; background: var(--surface); box-shadow: var(--shadow-card); }
.territory-tile-btn { padding: 7px 14px; border: 0; border-radius: 7px; color: var(--ink-soft); background: transparent; font-size: 12.5px; font-weight: 700; cursor: pointer; }
.territory-tile-btn.is-active { color: #fff; background: var(--brand-600); }
.territory-legend { position: absolute; bottom: 12px; left: 12px; z-index: 500; padding: 10px 14px; border-radius: 10px; background: rgba(255, 255, 255, .95); box-shadow: var(--shadow-card); font-size: 11.5px; }
.territory-legend strong { display: block; margin-bottom: 6px; color: var(--ink); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.territory-legend span { display: flex; align-items: center; gap: 7px; margin-top: 4px; color: var(--ink-soft); }
.territory-legend i { display: inline-block; width: 9px; height: 9px; border-radius: 50%; }
.territory-map-foot { padding: 12px 20px 18px; color: var(--ink-faint); font-size: 11px; }

/* Despesas fixas — recurrence banner, selectable rows, detail panel */
.fixed-expenses-main { display: flex; flex-direction: column; }
.fixed-expenses-title-row { display: flex; align-items: center; gap: 8px; }
.fixed-expenses-title-row h3 { font-size: 16px; font-weight: 600; letter-spacing: -.01em; color: var(--ink); }
.fixed-expenses-recurrence-banner { display: flex; align-items: center; gap: 12px; margin-top: 16px; padding: 14px 18px; border: 1px solid var(--warn-line); border-radius: 14px; background: var(--warn-pale); }
.fixed-expenses-recurrence-banner svg { flex: 0 0 20px; width: 20px; height: 20px; color: var(--warn); }
.fixed-expenses-recurrence-banner strong { color: var(--warn); font-size: 13px; font-weight: 700; }
.fixed-expenses-recurrence-banner div { flex: 1; }
.link-button { border: 0; background: transparent; color: var(--brand-700); font-size: 12.5px; font-weight: 600; white-space: nowrap; }
.link-button:hover { text-decoration: underline; }
.fixed-expense-row { cursor: pointer; }
.fixed-expense-row.is-selected { background: var(--brand-50); }
.fixed-expense-row-menu { text-align: right; }
.fixed-expense-row-menu .icon-button { width: 26px; height: 26px; border-radius: 7px; font-size: 16px; }
.fixed-expense-row-menu .icon-button:hover { background: var(--line-soft); }
.fixed-expense-detail-body { display: flex; flex-direction: column; gap: 10px; padding: 0 20px 20px; }
.fixed-expense-detail-title { font-size: 17px; font-weight: 700; letter-spacing: -.01em; color: var(--ink); }
.fixed-expense-detail-amount { font-size: 24px; font-weight: 700; letter-spacing: -.02em; color: var(--ink); font-variant-numeric: tabular-nums; }
.fixed-expense-detail-body .detail-grid { margin-top: 4px; }
.fixed-expense-detail-edit { width: 100%; justify-content: center; margin-top: 10px; }
.fixed-expense-detail-link { width: 100%; justify-content: center; }

/* Notícias — layout, hero/secondary/compact cards, sidebar */
.news-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 16px; align-items: start; }
.news-sidebar { display: flex; flex-direction: column; gap: 16px; }
@media (max-width: 1150px) { .news-layout { grid-template-columns: 1fr; } }
.news-date-pill { display: inline-flex; align-items: center; gap: 7px; padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink-soft); font-size: 12px; font-weight: 600; }
.news-date-pill svg { width: 14px; height: 14px; color: var(--ink-faint); }
.news-refresh-btn { color: var(--brand-700); border-color: var(--brand-200); }
.news-refresh-btn:hover { background: var(--brand-50); border-color: var(--brand-300, var(--brand-200)); }
.news-saved-toggle { display: inline-flex; align-items: center; gap: 7px; margin-left: auto; padding: 0 14px; height: 34px; border: 1px solid var(--line); border-radius: 7px; color: var(--ink-soft); background: var(--surface); font-size: 12.5px; font-weight: 600; white-space: nowrap; }
.news-saved-toggle svg { width: 14px; height: 14px; }
.news-saved-toggle:hover { border-color: var(--brand-200); color: var(--ink); }
.news-saved-toggle.is-active { border-color: var(--brand-600); color: var(--brand-700); background: var(--brand-50); }
.news-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.news-chip { padding: 7px 13px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink-soft); background: var(--surface); font-size: 12px; font-weight: 600; }
.news-chip:hover { border-color: var(--brand-200); color: var(--ink); }
.news-chip.is-active { border-color: var(--brand-600); color: #fff; background: var(--brand-600); }
.news-chip-count { padding: 0 6px; border-radius: 999px; background: var(--line-soft); color: var(--ink-soft); font-size: 10px; font-weight: 700; }
.news-chip.is-active .news-chip-count { background: rgba(255, 255, 255, .25); color: #fff; }
.news-status-line { display: flex; align-items: center; gap: 7px; padding: 0 20px 14px; color: var(--ink-faint); font-size: 11.5px; }
.news-status-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--ok); }
.news-card { position: relative; display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--line-soft); border-radius: 14px; background: var(--surface); transition: border-color .12s ease, box-shadow .12s ease, transform .12s ease; }
.news-card:hover { border-color: var(--line); box-shadow: 0 4px 14px rgba(15, 23, 42, .08); transform: translateY(-1px); }
.news-card-open { display: flex; flex-direction: column; width: 100%; height: 100%; border: 0; padding: 0; background: transparent; text-align: left; font: inherit; color: inherit; cursor: pointer; }
.news-thumb { display: block; aspect-ratio: 16 / 9; overflow: hidden; background: var(--line-soft); }
.news-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.news-card-body { display: flex; flex-direction: column; gap: 8px; flex: 1; padding: 16px; }
.news-card-meta { display: flex; align-items: center; gap: 8px; }
.news-source { color: var(--brand-700); font-size: 10.5px; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; }
.news-cat-badge { display: inline-flex; align-items: center; padding: 3px 10px; border-radius: 999px; color: var(--brand-700); background: var(--brand-50); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; }
.news-highlight-pill { padding: 3px 10px; border-radius: 999px; color: var(--warn); background: var(--warn-pale); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; }
.news-title { color: var(--ink); font-size: 14px; font-weight: 700; line-height: 1.35; }
.news-title--lg { font-size: 22px; line-height: 1.25; }
.news-summary { color: var(--ink-soft); font-size: 12.5px; line-height: 1.5; }
.news-card-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: auto; padding-top: 4px; }
.news-card-foot time, .news-card-foot .news-source { color: var(--ink-faint); font-size: 10.5px; font-weight: 500; text-transform: none; letter-spacing: 0; }
.news-link { color: var(--brand-700); font-size: 11.5px; font-weight: 600; white-space: nowrap; }
.news-bookmark-btn { position: absolute; top: 10px; right: 10px; z-index: 2; display: grid; place-items: center; width: 30px; height: 30px; border: 0; border-radius: 9px; color: var(--ink-soft); background: rgba(255, 255, 255, .92); box-shadow: var(--shadow-soft); cursor: pointer; }
.news-bookmark-btn svg { width: 15px; height: 15px; }
.news-bookmark-btn:hover { color: var(--brand-700); }
.news-bookmark-btn.is-saved { color: var(--brand-600); }
.news-card--hero { margin: 0 20px 14px; }
.news-card--hero .news-thumb { aspect-ratio: 21 / 9; }
.news-card--hero .news-title--lg { margin-top: 2px; }
.news-secondary-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 0 20px 14px; }
@media (max-width: 700px) { .news-secondary-grid { grid-template-columns: 1fr; } }
.news-compact-list { display: flex; flex-direction: column; margin: 0 20px 20px; border: 1px solid var(--line-soft); border-radius: 14px; overflow: hidden; }
.news-compact-row { display: flex; align-items: center; gap: 12px; padding: 13px 16px; border-top: 1px solid var(--line-soft); }
.news-compact-row:first-child { border-top: 0; }
.news-compact-open { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; border: 0; padding: 0; background: transparent; text-align: left; font: inherit; color: inherit; cursor: pointer; }
.news-compact-open strong { color: var(--ink); font-size: 13px; font-weight: 600; line-height: 1.35; }
.news-compact-open span { color: var(--ink-faint); font-size: 11px; }
.news-compact-actions { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }
.news-compact-actions .news-bookmark-btn { position: static; box-shadow: none; background: transparent; }
.news-ai-card { background: linear-gradient(180deg, var(--brand-50), var(--surface) 60%); border-color: var(--brand-100); }
.news-ai-summary { color: var(--ink-soft); font-size: 12.5px; line-height: 1.55; margin-bottom: 12px; }
.panel-muted { color: var(--ink-faint); font-size: 12px; line-height: 1.5; }
/* Mapa eleitoral — header actions, empty-state illustration, how-to cards */
.page-actions-row { display: flex; align-items: center; justify-content: flex-end; margin-bottom: 16px; }
.electoral-empty-card { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 44px 24px 36px; margin-bottom: 16px; border: 1px solid var(--line); border-radius: 18px; background: var(--brand-50); }
.electoral-empty-illustration { width: 150px; height: 120px; margin-bottom: 18px; }
.electoral-empty-card h3 { font-size: 22px; font-weight: 700; letter-spacing: -.01em; color: var(--ink); }
.electoral-empty-card p { max-width: 460px; margin-top: 8px; color: var(--ink-soft); font-size: 13.5px; line-height: 1.5; }
.electoral-empty-actions { display: flex; gap: 10px; margin-top: 22px; }
.electoral-empty-note { display: block; margin-top: 16px; color: var(--ink-faint); font-size: 11.5px; }
.electoral-info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 800px) { .electoral-info-grid { grid-template-columns: 1fr; } }
.electoral-steps { display: flex; flex-direction: column; gap: 12px; list-style: none; margin: 0; padding: 0; }
.electoral-steps li { display: flex; align-items: center; gap: 12px; color: var(--ink); font-size: 13px; font-weight: 500; }
.electoral-step-num { display: grid; flex: 0 0 24px; place-items: center; width: 24px; height: 24px; border-radius: 50%; color: var(--brand-700); background: var(--brand-100); font-size: 11.5px; font-weight: 700; }
.electoral-bullets { display: flex; flex-direction: column; gap: 12px; list-style: none; margin: 0; padding: 0; }
.electoral-bullets li { display: flex; align-items: center; gap: 10px; color: var(--ink); font-size: 13px; font-weight: 500; }
.electoral-bullets li svg { flex: 0 0 17px; width: 17px; height: 17px; color: var(--brand-600); }
.news-theme-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.news-saved-list { display: flex; flex-direction: column; gap: 2px; }
.news-saved-row { display: flex; flex-direction: column; gap: 2px; width: 100%; padding: 9px 2px; border: 0; border-top: 1px solid var(--line-soft); background: transparent; text-align: left; font: inherit; cursor: pointer; }
.news-saved-row:first-child { border-top: 0; }
.news-saved-row strong { color: var(--ink); font-size: 12.5px; font-weight: 600; line-height: 1.35; }
.news-saved-row span { color: var(--ink-faint); font-size: 11px; }
.news-saved-row:hover strong { color: var(--brand-700); }
/* In-app article reader */
.news-reader { position: fixed; inset: 0; z-index: 60; display: flex; justify-content: center; align-items: flex-start; padding: 40px 20px; background: rgba(15, 23, 42, .55); backdrop-filter: blur(3px); overflow-y: auto; }
.news-reader-panel { position: relative; width: 100%; max-width: 720px; border-radius: 18px; background: var(--surface); box-shadow: 0 24px 60px rgba(15, 23, 42, .3); }
.news-reader-close { position: absolute; top: 14px; right: 14px; display: grid; place-items: center; width: 32px; height: 32px; border: 0; border-radius: 9px; color: var(--ink-soft); background: var(--line-soft); font-size: 14px; cursor: pointer; }
.news-reader-close:hover { color: var(--ink); background: var(--line); }
.news-reader-body { padding: 34px 40px 40px; }
.news-reader-loading { padding: 20px 0; color: var(--ink-soft); font-size: 14px; }
.news-reader-source { color: var(--brand-700); font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.news-reader-title { margin: 8px 0 18px; font-size: 26px; font-weight: 700; line-height: 1.2; color: var(--ink); }
.news-reader-image { width: 100%; border-radius: 12px; margin-bottom: 18px; }
.news-reader-text p { margin: 0 0 14px; color: var(--ink); font-size: 15px; line-height: 1.6; }
.news-reader-origin { display: inline-block; margin-top: 10px; color: var(--brand-700); font-size: 13px; font-weight: 600; text-decoration: none; }
.news-reader-origin:hover { text-decoration: underline; }
/* Campaigns */
.campaign-layout { display: grid; grid-template-columns: 1.3fr 1fr; gap: 18px; align-items: start; }
.campaign-form { display: flex; flex-direction: column; gap: 14px; padding: 18px 20px; }
.campaign-channels { display: flex; gap: 10px; }
.campaign-channel { display: inline-flex; align-items: center; gap: 8px; padding: 9px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--ink-soft); font-size: 13px; font-weight: 600; cursor: pointer; transition: all .12s ease; }
.campaign-channel-ic { display: grid; place-items: center; width: 18px; height: 18px; }
.campaign-channel-ic svg { width: 16px; height: 16px; }
.campaign-channel.is-on { border-color: var(--brand-600); color: var(--brand-700); background: var(--brand-50); }
.campaign-preview { display: flex; flex-direction: column; gap: 14px; padding: 4px; position: sticky; top: 84px; }
.campaign-preview-title { color: var(--ink-faint); font-size: 10.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.wa-preview { border-radius: 16px; overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow-soft); }
.wa-head { display: flex; align-items: center; gap: 10px; padding: 11px 14px; color: #fff; background: #075E54; }
.wa-avatar { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: rgba(255,255,255,.2); font-size: 12px; font-weight: 700; }
.wa-head strong { display: block; font-size: 13px; }
.wa-head span { font-size: 10.5px; opacity: .85; }
.wa-body { padding: 18px 14px; background: #E5DDD5; min-height: 120px; }
.wa-bubble { position: relative; max-width: 85%; padding: 8px 12px; border-radius: 10px 10px 10px 2px; background: #fff; color: #111; font-size: 13px; line-height: 1.4; white-space: pre-wrap; word-break: break-word; box-shadow: 0 1px 1px rgba(0,0,0,.12); }
.email-preview { border: 1px solid var(--line); border-radius: 14px; overflow: hidden; box-shadow: var(--shadow-soft); background: var(--surface); }
.email-head { display: flex; flex-direction: column; gap: 3px; padding: 14px 16px; border-bottom: 1px solid var(--line); background: var(--paper); }
.email-from { color: var(--ink-faint); font-size: 11px; }
.email-subject { color: var(--ink); font-size: 14px; font-weight: 700; }
.email-body { padding: 16px; color: var(--ink); font-size: 13px; line-height: 1.5; white-space: pre-wrap; word-break: break-word; min-height: 110px; }
.campaign-history { padding: 6px 20px 14px; }
.campaign-history-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 12px 0; border-top: 1px solid var(--line-soft); }
.campaign-history-row:first-child { border-top: 0; }
.campaign-history-main strong { display: block; color: var(--ink); font-size: 13px; font-weight: 600; }
.campaign-history-main span { color: var(--ink-faint); font-size: 11px; }
.campaign-history-stats { display: flex; align-items: center; gap: 10px; }
.campaign-stat { font-size: 11px; font-weight: 600; color: var(--ink-soft); }
.campaign-stat.ok { color: var(--ok); }
.campaign-stat.bad { color: var(--danger); }
.campaign-history-stats time { color: var(--ink-faint); font-size: 10.5px; }
@media (max-width: 1100px) { .campaign-layout { grid-template-columns: 1fr; } .campaign-preview { position: static; } }
.territory-map .leaflet-container { font: inherit; background: var(--surface); cursor: grab; touch-action: none; overscroll-behavior: contain; }
.territory-map .leaflet-container.leaflet-drag-target, .territory-map .leaflet-dragging .leaflet-grab { cursor: grabbing; }
.territory-dot { filter: drop-shadow(0 1px 2px rgba(15, 23, 42, .35)); cursor: pointer; }
.territory-pin-wrap { position: relative; display: grid; place-items: center; cursor: pointer; }
.territory-pin { position: relative; z-index: 1; display: grid; place-items: center; border: 3px solid #fff; border-radius: 50% 50% 50% 0; background: var(--pin-color); box-shadow: 0 2px 6px rgba(15, 23, 42, .35); transform: rotate(-45deg); }
.territory-pin-label { transform: rotate(45deg); color: #fff; font-size: 12px; font-weight: 700; font-variant-numeric: tabular-nums; }
.territory-pin-halo { position: absolute; top: 50%; left: 50%; width: 46px; height: 46px; margin: -23px 0 0 -23px; border-radius: 50%; opacity: .22; animation: territory-pulse 2s ease-out infinite; }
@keyframes territory-pulse { 0% { transform: scale(.6); opacity: .35; } 100% { transform: scale(1.6); opacity: 0; } }
.territory-popup .leaflet-popup-content-wrapper { border-radius: 14px; box-shadow: 0 10px 30px rgba(15, 23, 42, .18); }
.territory-popup .leaflet-popup-content { margin: 14px 16px; font: inherit; }
.territory-pop { text-align: center; }
.territory-pop-head { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.territory-pop-head strong { font-size: 14px; font-weight: 700; color: var(--ink); }
.territory-pop-topic { color: var(--brand-700); font-size: 10px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.territory-pop-count { margin-top: 2px; color: var(--ink-soft); font-size: 12px; font-weight: 600; }
.territory-pop-meta { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.territory-pop-tag { padding: 2px 8px; border-radius: 999px; font-size: 10px; font-weight: 700; }
.territory-pop-tag.is-critical { color: var(--danger); background: var(--danger-pale); }
.territory-pop-tag.is-incident { color: var(--warn); background: var(--warn-pale); }
.territory-pop-list { list-style: none; margin: 12px 0 4px; padding: 0; display: flex; flex-direction: column; gap: 10px; max-height: 240px; overflow-y: auto; }
.territory-pop-item { display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 10px 8px; margin: 0 -8px; border-top: 1px solid var(--line-soft); border-radius: 8px; cursor: pointer; transition: background .12s ease; }
.territory-pop-item:first-child { border-top: 0; }
.territory-pop-item:hover { background: var(--brand-50); }
.territory-pop-item-by { color: var(--ink-soft); font-size: 10.5px; }
.territory-pop-item-by::before { content: "👤 "; }
.territory-pop-item-link { margin-top: 2px; color: var(--brand-700); font-size: 11px; font-weight: 600; }
.territory-pop-item-top { display: flex; align-items: center; gap: 8px; }
.territory-pop-proto { color: var(--ink-faint); font-size: 10.5px; font-weight: 600; font-variant-numeric: tabular-nums; }
.territory-pop-item strong { color: var(--ink); font-size: 12.5px; font-weight: 600; line-height: 1.3; }
.territory-pop-item-sub { color: var(--ink-faint); font-size: 10.5px; }
.territory-pop-sla { color: var(--warn); font-weight: 600; }
.territory-pop-link { display: inline-block; margin-top: 10px; color: var(--brand-700); font-size: 12px; font-weight: 600; text-decoration: none; }
.territory-pop-link:hover { text-decoration: underline; }
.territory-map .leaflet-control-zoom a { border-radius: 7px; color: var(--ink-soft); }
.territory-map .leaflet-control-attribution { font-size: 9px; }

.automation-toggle-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; padding: 20px; }
.automation-toggle-head { display: flex; align-items: center; gap: 10px; }
.automation-toggle-icon { display: grid; flex: 0 0 30px; place-items: center; width: 30px; height: 30px; border-radius: 8px; color: var(--brand-700); background: var(--brand-50); }
.automation-toggle-icon svg { width: 15px; height: 15px; }
.automation-toggle-head h4 { flex: 1; min-width: 0; font-size: 13px; font-weight: 600; color: var(--ink); }
.automation-toggle-card > p { margin-top: 12px; color: var(--ink-soft); font-size: 12px; line-height: 1.5; }
.automation-message-preview { margin-top: 10px; padding: 10px 12px; border-radius: 10px; background: var(--line-soft); color: var(--ink-soft); font-size: 11.5px; line-height: 1.5; }
.automation-toggle-footer { display: flex; align-items: center; justify-content: space-between; margin-top: 12px; color: var(--ink-faint); font-size: 10.5px; }
.toggle-switch { position: relative; flex: 0 0 34px; width: 34px; height: 20px; border: 0; border-radius: 999px; background: var(--line); padding: 2px; }
.toggle-switch.is-on { background: var(--dark-ink); }
.toggle-knob { display: block; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: var(--shadow-soft); transition: transform .15s ease; }
.toggle-switch.is-on .toggle-knob { transform: translateX(14px); }
@media (max-width: 980px) {
  .automation-toggle-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  .automation-toggle-grid { grid-template-columns: 1fr; }
}

.report-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.reports-period { display: inline-flex; gap: 6px; padding: 3px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.reports-period-chip { padding: 8px 14px; border: 0; border-radius: 8px; background: transparent; color: var(--ink-soft); font-size: 12.5px; font-weight: 600; font-family: inherit; cursor: pointer; }
.reports-period-chip:hover { color: var(--ink); }
.reports-period-chip.is-active { background: var(--brand-600); color: #fff; }

.integration-icon { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; color: var(--brand-700); background: var(--brand-50); }
.integration-icon svg { width: 17px; height: 17px; }
.integration-icon img { width: 20px; height: 20px; object-fit: contain; }
.integration-icon .integration-logo-img { width: 22px; height: 22px; }
.integration-icon .integration-logo-mono { display: grid; place-items: center; width: 100%; height: 100%; border-radius: 9px; background: var(--logo-color, var(--brand-700)); color: #fff; font-size: 10px; font-weight: 800; letter-spacing: .02em; }

.ai-page { display: flex; flex-direction: column; min-height: 520px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); box-shadow: var(--shadow-soft); overflow: hidden; }
.ai-thread { flex: 1; min-height: 360px; max-height: 60vh; padding: 24px; overflow-y: auto; display: flex; flex-direction: column; gap: 16px; }
.ai-message { display: flex; }
.ai-message-assistant { align-items: flex-start; gap: 10px; }
.ai-message-user { justify-content: flex-end; }
.ai-message-avatar { display: grid; flex: 0 0 30px; place-items: center; width: 30px; height: 30px; border-radius: 50%; color: #fff; background: var(--dark-ink); }
.ai-message-avatar svg { width: 14px; height: 14px; }
.ai-message-bubble { max-width: 560px; padding: 12px 15px; border-radius: 14px; font-size: 13px; line-height: 1.55; }
.ai-message-assistant .ai-message-bubble { border: 1px solid var(--line); background: var(--paper); color: var(--ink); border-top-left-radius: 4px; }
.ai-message-user .ai-message-bubble { background: var(--dark-ink); color: #fff; border-top-right-radius: 4px; }
.ai-composer { border-top: 1px solid var(--line); padding: 16px 24px; background: var(--surface); }
.ai-suggestion-row { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 12px; }
.ai-input-wrap { display: flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 999px; padding: 4px 6px 4px 14px; background: var(--paper); }
.ai-input-wrap:focus-within { border-color: var(--dark-ink); box-shadow: 0 0 0 3px rgba(23, 125, 98, .18); }
.ai-input-spark { display: grid; place-items: center; color: var(--ink); }
.ai-input-spark svg { width: 15px; height: 15px; }
.ai-input-wrap input { flex: 1; min-width: 0; padding: 10px 0; border: 0; outline: 0; background: transparent; color: var(--ink); font-size: 13px; }
.ai-input-wrap button { display: grid; place-items: center; flex: 0 0 34px; width: 34px; height: 34px; border: 0; border-radius: 50%; color: #fff; background: var(--dark-ink); }
.ai-input-wrap button:hover { background: var(--brand-900); }
.ai-input-wrap button svg { width: 15px; height: 15px; }

.inbox-split { display: flex; min-height: 540px; }
.inbox-list-pane { display: flex; flex-direction: column; flex: 0 0 320px; border-right: 1px solid var(--line); }
.inbox-search { display: flex; align-items: center; gap: 8px; margin: 16px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); }
.inbox-search svg { flex: 0 0 15px; width: 15px; height: 15px; color: var(--ink-faint); }
.inbox-search input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; color: var(--ink); font-size: 12.5px; }
.inbox-row-list { flex: 1; overflow-y: auto; }
.inbox-row { display: flex; align-items: flex-start; gap: 10px; width: 100%; padding: 12px 16px; border: 0; border-top: 1px solid var(--line-soft); background: transparent; text-align: left; }
.inbox-row:first-child { border-top: 0; }
.inbox-row:hover { background: var(--paper); }
.inbox-row.is-active { background: var(--brand-50); }
.inbox-row-avatar { display: grid; flex: 0 0 32px; place-items: center; width: 32px; height: 32px; border-radius: 50%; color: var(--brand-700); background: var(--brand-100); font-size: 11px; font-weight: 700; }
.inbox-row-avatar-lg { flex: 0 0 40px; width: 40px; height: 40px; font-size: 13px; }
.inbox-row-body { flex: 1; min-width: 0; }
.inbox-row-top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.inbox-row-top strong { overflow: hidden; color: var(--ink); font-size: 12.5px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.inbox-row-top time { flex: 0 0 auto; color: var(--ink-faint); font-size: 9.5px; }
.inbox-row-bottom { display: flex; align-items: center; gap: 6px; margin-top: 5px; }
.inbox-row-channel { color: var(--ink-faint); font-size: 10.5px; }
.channel-chip { display: inline-flex; align-items: center; gap: 4px; padding: 2px 7px 2px 5px; border-radius: 999px; font-size: 10.5px; font-weight: 600; line-height: 1.4; background: var(--line-soft); color: var(--ink-soft); }
.channel-chip svg { width: 13px; height: 13px; flex-shrink: 0; }
.channel-chip-whatsapp { background: #e7f7ee; color: #128c4b; }
.channel-chip-email { background: var(--brand-50); color: var(--brand-700); }
.sla-chip { display: inline-flex; align-items: center; padding: 2px 8px; border-radius: 999px; font-size: 11px; font-weight: 600; background: var(--line-soft); color: var(--ink-soft); white-space: nowrap; }
.sla-chip.sla-soon { background: var(--warn-pale); color: var(--warn); }
.sla-chip.sla-late { background: var(--danger-pale); color: var(--danger); }
.sla-chip.sla-ok { background: transparent; color: var(--ink-faint); font-weight: 500; }
.inbox-detail-pane { flex: 1; min-width: 0; }
.inbox-empty-detail { display: flex; height: 100%; min-height: 540px; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: 24px; text-align: center; }
.inbox-empty-icon { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; color: var(--ink-faint); background: var(--line-soft); }
.inbox-empty-icon svg { width: 22px; height: 22px; }
.inbox-empty-detail strong { color: var(--ink); font-size: 14px; }
.inbox-empty-detail p { max-width: 280px; color: var(--ink-faint); font-size: 12px; line-height: 1.5; }
.inbox-detail-head { display: flex; align-items: center; gap: 12px; padding: 20px 24px; border-bottom: 1px solid var(--line); }
.inbox-detail-head .inbox-detail-title { flex: 1; min-width: 0; }
.inbox-detail-head #inbox-create-demand { flex: 0 0 auto; }
.inbox-detail-title strong { display: block; color: var(--ink); font-size: 14px; }
.inbox-detail-title span { display: flex; align-items: center; gap: 6px; margin-top: 4px; color: var(--ink-faint); font-size: 11px; }
.inbox-detail-grid { margin: 20px 24px 0; }
.inbox-detail-note { margin: 18px 24px 24px; padding: 12px 14px; border-radius: 10px; background: var(--paper); color: var(--ink-faint); font-size: 11.5px; line-height: 1.55; }
@media (max-width: 760px) {
  .inbox-split { flex-direction: column; }
  .inbox-list-pane { flex: none; border-right: 0; border-bottom: 1px solid var(--line); }
}

.agenda-toolbar { display: flex; align-items: center; justify-content: space-between; padding: 14px 20px; border-bottom: 1px solid var(--line); background: var(--paper); }
.agenda-nav { display: flex; align-items: center; gap: 10px; }
.agenda-nav-arrow { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 7px; color: var(--ink-soft); }
.agenda-nav-arrow:hover { color: var(--ink); background: var(--line-soft); }
.agenda-nav-arrow svg { width: 15px; height: 15px; }
.agenda-month-label { margin-left: 6px; font-size: 14px; font-weight: 600; color: var(--ink); }
.agenda-modes { display: inline-flex; gap: 2px; padding: 2px; border: 1px solid var(--line); border-radius: 9px; background: var(--paper); }
.agenda-mode { padding: 5px 12px; border: 0; border-radius: 7px; color: var(--ink-soft); background: transparent; font-size: 12px; font-weight: 600; cursor: pointer; }
.agenda-mode:hover { color: var(--ink); }
.agenda-mode.is-active { color: var(--ink); background: var(--surface); box-shadow: 0 1px 2px rgba(0, 0, 0, .06); }
.agenda-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.agenda-grid--week .agenda-cell { min-height: 320px; }
.agenda-grid--day { grid-template-columns: 1fr; }
.agenda-grid--day .agenda-cell { min-height: 420px; border-right: 0; }
.agenda-cell-weekday { margin-right: 6px; color: var(--ink-faint); font-size: 10px; font-weight: 700; letter-spacing: .06em; }
.agenda-cell-date { align-self: flex-start; }
.agenda-grid--day .agenda-cell.is-today .agenda-cell-date { width: auto; height: auto; padding: 2px 8px; border-radius: 8px; color: var(--brand-700); background: var(--brand-100); }
.agenda-weekday { padding: 10px 8px; color: var(--ink-faint); font-size: 10px; font-weight: 700; letter-spacing: .06em; text-align: center; border-bottom: 1px solid var(--line); }
.agenda-cell { position: relative; min-width: 0; min-height: 124px; padding: 6px 6px 8px; border-right: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); display: flex; flex-direction: column; gap: 4px; cursor: pointer; transition: background .12s ease; }
.agenda-cell:hover { background: var(--line-soft); }
.agenda-cell:focus-visible { outline: 2px solid var(--dark-ink); outline-offset: -2px; }
.agenda-cell-add { position: absolute; top: 5px; right: 6px; display: grid; place-items: center; width: 18px; height: 18px; border-radius: 6px; color: var(--ink-faint); background: var(--surface); font-size: 14px; line-height: 1; opacity: 0; transition: opacity .12s ease; }
.agenda-cell:hover .agenda-cell-add { opacity: 1; }
.agenda-chip { cursor: pointer; }
.agenda-cell:nth-child(7n) { border-right: 0; }
.agenda-cell.is-outside { background: var(--paper); }
.agenda-cell.is-outside .agenda-cell-date { color: var(--ink-faint); }
.agenda-cell-date { padding: 2px 6px; font-size: 11.5px; font-weight: 600; color: var(--ink); }
.agenda-cell.is-today .agenda-cell-date { display: inline-flex; align-items: center; justify-content: center; width: 20px; height: 20px; padding: 0; border-radius: 50%; color: #fff; background: var(--dark-ink); }
.agenda-cell-chips { display: flex; flex-direction: column; gap: 4px; overflow: hidden; }
.agenda-chip { display: -webkit-box; width: 100%; overflow: hidden; border-radius: 7px; border: 1px solid; padding: 4px 8px; font-size: 11px; font-weight: 600; line-height: 1.35; text-align: left; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.agenda-chip-more { padding: 0 6px; color: var(--ink-faint); font-size: 10px; }
.agenda-chip.is-selected { outline: 2px solid var(--brand-600); outline-offset: 1px; }
.agenda-chip.is-canceled { opacity: .55; text-decoration: line-through; }
.agenda-chip.is-done { opacity: .7; }
/* Agenda — layout, filters/legend, inline detail panel, list mode */
.agenda-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 16px; align-items: start; }
@media (max-width: 1150px) { .agenda-layout { grid-template-columns: 1fr; } }
.agenda-filters-row { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; padding: 13px 20px; border-bottom: 1px solid var(--line); }
.agenda-legend { display: flex; flex-wrap: wrap; gap: 14px; margin-left: auto; }
.agenda-legend-item { display: flex; align-items: center; gap: 6px; color: var(--ink-soft); font-size: 12px; }
.agenda-legend-item i { display: inline-block; width: 8px; height: 8px; border-radius: 50%; }
.agenda-illustrative-note { padding: 10px 20px; color: var(--ink-faint); font-size: 10.5px; }
.agenda-side-col { display: flex; flex-direction: column; gap: 16px; }
.agenda-detail-close { width: 26px; height: 26px; margin-left: auto; border-radius: 7px; color: var(--ink-faint); }
.agenda-detail-close:hover { color: var(--ink); background: var(--line-soft); }
.agenda-tip-card { display: flex; align-items: flex-start; gap: 10px; padding: 14px 16px; border: 1px solid var(--brand-100); border-radius: 14px; background: var(--brand-50); }
.agenda-tip-ic { flex: 0 0 auto; color: var(--brand-600); font-size: 14px; }
.agenda-tip-card strong { display: block; color: var(--ink); font-size: 12.5px; font-weight: 700; }
.agenda-tip-card p { margin: 3px 0 0; color: var(--ink-soft); font-size: 11.5px; line-height: 1.45; }
.agenda-detail-panel { padding: 0; }
.agenda-detail-panel .panel-heading { margin: 0; }
.agenda-detail-panel #agenda-detail-body { padding: 18px 20px 20px; display: flex; flex-direction: column; gap: 12px; }
.agenda-detail-panel #agenda-detail-body > .empty-state { padding: 30px 0; }
.agenda-detail-title { font-size: 18px; font-weight: 700; line-height: 1.3; color: var(--ink); }
.agenda-detail-row { display: flex; align-items: center; gap: 9px; color: var(--ink-soft); font-size: 13px; }
.agenda-detail-row svg { flex: 0 0 16px; width: 16px; height: 16px; color: var(--ink-faint); }
.agenda-detail-row a { color: var(--brand-700); }
.agenda-detail-notes { display: flex; flex-direction: column; gap: 6px; margin-top: 4px; }
.agenda-detail-notes span { color: var(--ink-faint); font-size: 11px; font-weight: 600; }
.agenda-detail-notes textarea { padding: 9px 11px; border: 1px solid var(--line); border-radius: 9px; color: var(--ink); background: var(--surface); font: inherit; font-size: 12.5px; resize: vertical; }
.agenda-detail-actions { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; }
.agenda-detail-actions button { width: 100%; justify-content: center; }
.agenda-detail-actions button svg { flex: 0 0 15px; width: 15px; height: 15px; }
.agenda-list { display: flex; flex-direction: column; padding: 4px 20px 16px; }
.agenda-list-day { padding: 14px 0 6px; color: var(--ink-faint); font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.agenda-list-row { display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px 10px; border: 0; border-radius: 10px; background: transparent; text-align: left; font: inherit; cursor: pointer; }
.agenda-list-row:hover { background: var(--line-soft); }
.agenda-list-row.is-active { background: var(--brand-50); }
.agenda-list-time { flex: 0 0 46px; color: var(--ink-faint); font-size: 11.5px; font-weight: 600; font-variant-numeric: tabular-nums; }
.agenda-list-dot { flex: 0 0 8px; width: 8px; height: 8px; border-radius: 50%; }
.agenda-list-body strong { display: block; color: var(--ink); font-size: 13px; font-weight: 600; }
.agenda-list-body span { display: block; margin-top: 2px; color: var(--ink-faint); font-size: 11px; }
@media (max-width: 760px) {
  .agenda-cell { min-height: 70px; }
  .agenda-weekday { font-size: 9px; padding: 8px 4px; }
}
.integrations-layout { display: flex; align-items: stretch; gap: 20px; padding: 20px; }
.integrations-configured { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.integration-accordion { border: 1px solid var(--line); border-radius: 14px; background: var(--surface); overflow: hidden; }
.integration-accordion.is-open { border-color: var(--line); }
.integration-accordion-head { display: flex; align-items: center; gap: 12px; width: 100%; padding: 14px 16px; border: 0; background: transparent; text-align: left; }
.integration-accordion-title { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.integration-accordion-title strong { font-size: 13px; font-weight: 600; color: var(--ink); }
.integration-accordion-title span { color: var(--ink-faint); font-size: 11px; }
.integration-accordion-chevron { flex: 0 0 15px; width: 15px; height: 15px; color: var(--ink-faint); transition: transform .15s ease; }
.integration-accordion.is-open .integration-accordion-chevron { transform: rotate(180deg); }
.integration-accordion-body { display: flex; flex-direction: column; gap: 12px; padding: 4px 16px 18px; border-top: 1px solid var(--line-soft); }
.integration-accordion-body .field-group { margin-top: 12px; }
.integration-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.integration-note { margin: 10px 0 0; color: var(--ink-faint); font-size: 11.5px; }
.integration-error { margin-top: 6px; padding: 9px 12px; border: 1px solid var(--danger); border-radius: 9px; background: color-mix(in srgb, var(--danger) 8%, transparent); color: var(--danger); font-size: 11.5px; }
.integration-result { margin-top: 6px; padding: 9px 12px; border-radius: 9px; font-size: 11.5px; }
.integration-result.is-ok { background: var(--brand-50); color: var(--brand-700); }
.integration-result.is-error { background: color-mix(in srgb, var(--danger) 8%, transparent); color: var(--danger); }
.integration-disconnect { color: var(--danger); }
.integrations-catalog { flex: 1; min-width: 0; border: 1px solid var(--line); border-radius: 14px; background: var(--paper); padding: 16px; }
.catalog-head { display: flex; align-items: center; gap: 8px; margin-bottom: 14px; color: var(--ink); font-size: 13px; font-weight: 700; }
.catalog-head svg { width: 15px; height: 15px; color: var(--brand-600); }
.catalog-group { margin-bottom: 16px; }
.catalog-group:last-child { margin-bottom: 0; }
.catalog-group-label { display: block; margin-bottom: 8px; color: var(--ink-faint); font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.catalog-row { display: flex; align-items: center; gap: 10px; padding: 8px 0; }
.catalog-row-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.catalog-row-body strong { font-size: 12.5px; font-weight: 600; color: var(--ink); }
.catalog-row-body span { overflow: hidden; color: var(--ink-faint); font-size: 10.5px; text-overflow: ellipsis; white-space: nowrap; }
.catalog-connected { flex: 0 0 auto; color: var(--ok); font-size: 10.5px; font-weight: 600; }
.catalog-dot { flex: 0 0 8px; width: 8px; height: 8px; border-radius: 50%; border: 1px solid var(--line); }
@media (max-width: 860px) {
  .integrations-layout { flex-direction: column; }
}

@media (max-width: 760px) {
  .report-grid { grid-template-columns: 1fr; }
  .data-table th, .data-table td { padding: 10px 14px; }
}

/* Loading skeletons */
@keyframes skeleton-pulse { 0%, 100% { opacity: .5; } 50% { opacity: 1; } }
.skeleton-row { display: flex; align-items: center; gap: 18px; padding: 15px 20px; border-bottom: 1px solid var(--line-soft); }
.skeleton-row:last-child { border-bottom: 0; }
.skeleton-bar { height: 10px; border-radius: 4px; background: var(--line-soft); animation: skeleton-pulse 1.3s ease-in-out infinite; }

/* Detail modal */
.detail-grid { display: grid; grid-template-columns: 132px 1fr; gap: 12px 16px; margin: 20px 0 0; }
.detail-grid dt { color: var(--ink-faint); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.detail-grid dd { margin: 0; color: var(--ink); font-size: 13px; line-height: 1.5; }
@media (max-width: 420px) {
  .detail-grid { grid-template-columns: 1fr; gap: 4px; }
  .detail-grid dt { margin-top: 10px; }
}
.detail-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 20px; }

/* Create button + forms */
.btn-create { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 14px; border: 0; border-radius: var(--radius-sm); background: var(--dark-ink); color: #fff; font-size: 12px; font-weight: 600; box-shadow: inset 0 0 0 1px var(--dark-ink); white-space: nowrap; transition: background .15s var(--ease), transform .15s var(--ease); }
.btn-create:hover { background: var(--brand-900); transform: translateY(-1px); }
.btn-secondary { display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 16px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); color: var(--ink-soft); font-size: 13px; font-weight: 600; text-decoration: none; transition: border-color .15s var(--ease), background .15s var(--ease); }
.btn-secondary:hover { border-color: var(--ink-faint); background: var(--paper); }
.btn-primary-action { display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 18px; border: 0; border-radius: var(--radius-sm); background: linear-gradient(135deg, var(--brand-600), var(--brand-700)); color: #fff; font-size: 13px; font-weight: 600; box-shadow: inset 0 0 0 1px var(--brand-700); text-decoration: none; transition: background .15s var(--ease), box-shadow .15s var(--ease), transform .15s var(--ease); }
.btn-primary-action:hover { background: var(--brand-700); box-shadow: var(--shadow-pop), inset 0 0 0 1px var(--brand-700); transform: translateY(-1px); }
.btn-primary-action:disabled { opacity: .6; cursor: not-allowed; }
body:has(> .app-shell) .btn-primary-action { background: var(--dark-ink); box-shadow: inset 0 0 0 1px var(--dark-ink); }
body:has(> .app-shell) .btn-primary-action:hover { background: var(--brand-900); }
.field-group { margin-top: 18px; }
.field-group label { display: block; margin-bottom: 6px; color: var(--ink-faint); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.field-input, .field-select, .field-textarea { width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); color: var(--ink); font-size: 13px; font-family: inherit; transition: border-color .15s var(--ease), box-shadow .15s var(--ease); }
.field-input:focus, .field-select:focus, .field-textarea:focus { outline: none; border-color: var(--brand-600); box-shadow: 0 0 0 3px rgba(37, 99, 235, .12); }
body:has(> .app-shell) .field-input:focus, body:has(> .app-shell) .field-select:focus, body:has(> .app-shell) .field-textarea:focus { border-color: var(--dark-ink); box-shadow: 0 0 0 3px rgba(23, 125, 98, .18); }
.field-textarea { resize: vertical; min-height: 70px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.field-row-address { grid-template-columns: 1fr 110px; }
.field-row-city { grid-template-columns: 1fr 1fr 80px; }
.form-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 22px; }
.form-error { margin-top: 14px; padding: 10px 12px; border-radius: 8px; background: var(--danger-pale); border: 1px solid var(--danger-line); color: var(--danger); font-size: 12px; }

/* Login page */
.login-shell { display: grid; grid-template-columns: 1fr 1fr; min-height: 100vh; background: var(--paper); }
.login-brand-panel { position: relative; display: flex; flex-direction: column; justify-content: space-between; padding: 44px; overflow: hidden; color: #EAF1FF; background: linear-gradient(160deg, var(--brand-900), var(--brand-950)); }
.login-brand-panel::before { content: ""; position: absolute; inset: -20%; background-image: linear-gradient(var(--brand-700) 1px, transparent 1px), linear-gradient(90deg, var(--brand-700) 1px, transparent 1px); background-size: 42px 42px; opacity: .22; transform: rotate(-8deg); }
.login-brand-top { position: relative; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.login-brand-panel .brand-lockup { padding: 0; }
.login-brand-panel .brand-logo-full { height: 42px; }
.login-back-link { display: inline-flex; align-items: center; gap: 6px; color: var(--brand-200); font-size: 12px; font-weight: 600; text-decoration: none; }
.login-back-link svg { width: 14px; height: 14px; }
.login-back-link:hover { color: #fff; }
.login-pitch { position: relative; z-index: 1; max-width: 400px; }
.login-pitch h2 { font-size: 28px; font-weight: 700; letter-spacing: -.02em; line-height: 1.25; color: #fff; }
.login-pitch p { margin-top: 14px; color: var(--brand-100); font-size: 13px; line-height: 1.6; }
.login-pitch-list { display: flex; flex-direction: column; gap: 12px; margin-top: 26px; }
.login-pitch-item { display: flex; align-items: center; gap: 10px; color: var(--brand-100); font-size: 12px; font-weight: 500; }
.login-pitch-item span { display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; color: #fff; background: rgba(255, 255, 255, .14); font-size: 11px; }
.login-footnote { position: relative; z-index: 1; display: flex; align-items: center; gap: 8px; color: var(--brand-200); font-size: 10px; }
.login-footnote img { height: 14px; width: auto; filter: brightness(0) invert(1); opacity: .7; }
.login-form-panel { display: flex; align-items: center; justify-content: center; padding: 44px; background: var(--surface); }
.login-card { width: 100%; max-width: 360px; }
.login-card .brand-lockup { padding: 0 0 30px; }
.login-card .brand-logo-full { height: 40px; }
.login-eyebrow { color: var(--brand-700); }
.login-card h1 { max-width: none; margin-top: 10px; font-size: 24px; }
.login-card .page-heading-note { margin-top: 8px; color: var(--ink-soft); font-size: 13px; }
.login-field-row { display: flex; align-items: center; justify-content: space-between; margin-top: 14px; }
.remember-me { display: flex; align-items: center; gap: 7px; color: var(--ink-soft); font-size: 12px; }
.remember-me input { width: 14px; height: 14px; accent-color: var(--brand-600); }
.forgot-link { color: var(--brand-700); font-size: 12px; font-weight: 600; text-decoration: none; }
.forgot-link:hover { color: var(--brand-600); }
.caps-lock-hint { display: flex; align-items: center; gap: 6px; margin-top: 7px; color: var(--warn); font-size: 11px; }
.password-wrap { position: relative; display: flex; align-items: center; }
.password-wrap .field-input { padding-right: 42px; width: 100%; }
.password-toggle { position: absolute; right: 8px; display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; padding: 0; border: 0; border-radius: 6px; background: transparent; color: var(--ink-faint); cursor: pointer; }
.password-toggle:hover { color: var(--ink); background: var(--line-soft); }
.password-toggle svg { width: 18px; height: 18px; }
.caps-lock-hint[hidden] { display: none; }
.login-submit { width: 100%; height: 44px; margin-top: 22px; justify-content: center; }
.login-security-note { margin-top: 22px; color: var(--ink-faint); font-size: 11px; }
.login-card-result { margin-top: 20px; padding: 18px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); }
.login-card-result[hidden] { display: none; }
.login-card-result-head { font-size: 14px; color: var(--ink-soft); margin-bottom: 12px; }
.login-card-result-head strong { color: var(--ink); }
.login-card-result-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 18px; margin: 0; }
.login-card-result-grid dt { font-size: 11px; text-transform: uppercase; letter-spacing: 0.04em; color: var(--ink-faint); }
.login-card-result-grid dd { margin: 2px 0 0; font-size: 14px; font-weight: 600; color: var(--ink); }
.login-card-result p { margin: 6px 0 0; font-size: 13px; color: var(--ink-soft); }
@media (max-width: 860px) {
  .login-shell { grid-template-columns: 1fr; }
  .login-brand-panel { display: none; }
  .login-form-panel { padding: 32px 20px; }
}

/* ---- Landing page (editorial style, mirrors app.burple.com.br) ---- */
.landing-page { font-family: "Inter", ui-sans-serif, system-ui, sans-serif; }
.landing-page h1, .landing-page h2, .landing-page h3 { font-family: "Lora", Georgia, serif; font-weight: 600; letter-spacing: -.01em; }

.landing-topbar { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 20px 46px; background: var(--surface); border-bottom: 1px solid var(--line); }
.landing-nav-links { display: flex; align-items: center; gap: 28px; }
.landing-nav-links a { color: var(--ink-soft); font-size: 13.5px; font-weight: 500; text-decoration: none; }
.landing-nav-links a:hover { color: var(--ink); }
.landing-topbar-actions { display: flex; align-items: center; gap: 18px; }
.landing-topbar-actions > a:first-child:not(.btn-dark-pill) { color: var(--ink-soft); font-size: 13.5px; font-weight: 500; text-decoration: none; }
.btn-dark-pill { display: inline-flex; align-items: center; gap: 8px; padding: 10px 18px; border-radius: 999px; color: #fff; background: var(--dark-ink); font-size: 13px; font-weight: 600; white-space: nowrap; text-decoration: none; }
.btn-dark-pill:hover { background: var(--brand-900); }
.btn-outline-pill { display: inline-flex; align-items: center; gap: 8px; padding: 10px 18px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink); background: var(--surface); font-size: 13px; font-weight: 600; white-space: nowrap; text-decoration: none; }
.btn-outline-pill:hover { border-color: var(--ink-faint); }

.landing-hero { display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; max-width: 1180px; margin: 0 auto; padding: 72px 46px 56px; }
.landing-hero-copy h1 { font-size: clamp(34px, 4vw, 46px); line-height: 1.12; color: var(--ink); }
.landing-hero-copy > p { max-width: 480px; margin-top: 18px; color: var(--ink-soft); font-size: 15px; line-height: 1.65; }
.landing-hero-actions { display: flex; align-items: center; gap: 12px; margin-top: 28px; }
.landing-hero-badges { display: flex; flex-wrap: wrap; gap: 18px; margin-top: 22px; }
.landing-hero-badges span { display: inline-flex; align-items: center; gap: 6px; color: var(--ink-faint); font-size: 12px; }
.landing-hero-badges svg { width: 13px; height: 13px; color: var(--ok); flex: 0 0 13px; }

.landing-feed-card { padding: 24px; border-radius: 16px; color: #fff; background: var(--dark-ink); box-shadow: none; }
.landing-feed-head { display: flex; align-items: center; gap: 8px; padding-bottom: 16px; margin-bottom: 4px; border-bottom: 1px solid var(--dark-line); font-size: 12.5px; font-weight: 600; }
.landing-feed-head .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--mint); }
.landing-feed-row { display: flex; gap: 14px; padding: 13px 0; border-bottom: 1px solid var(--dark-line); }
.landing-feed-row:last-of-type { border-bottom: 0; }
.landing-feed-time { flex: 0 0 38px; color: var(--dark-ink-soft); font-size: 11px; padding-top: 1px; }
.landing-feed-row strong { display: block; color: #fff; font-size: 12.5px; font-weight: 600; }
.landing-feed-row span { display: block; margin-top: 2px; color: var(--dark-ink-soft); font-size: 11.5px; }
.landing-feed-metric { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--dark-line); }
.landing-feed-metric span { color: var(--dark-ink-soft); font-size: 11px; }
.landing-feed-metric strong { font-family: "Lora", Georgia, serif; color: var(--mint); font-size: 30px; font-weight: 600; }

.landing-proof { padding: 30px 46px; text-align: center; background: var(--paper); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.landing-proof p { color: var(--ink-faint); font-size: 12px; margin-bottom: 18px; }
.landing-proof-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 40px; }
.landing-proof-row span { font-family: "Lora", Georgia, serif; color: var(--ink-faint); font-size: 17px; opacity: .65; }
.landing-references { max-width: 1120px; margin: 0 auto; padding: 64px 46px; }
.landing-references .landing-note { color: var(--ink-faint); font-size: 12.5px; }
.landing-ref-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 28px; }
.landing-ref-card { margin: 0; padding: 24px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); box-shadow: none; }
.landing-ref-card blockquote { margin: 0 0 16px; color: var(--ink); font-size: 15px; line-height: 1.55; }
.landing-ref-card figcaption strong { display: block; color: var(--ink); font-size: 13px; }
.landing-ref-card figcaption span { color: var(--ink-faint); font-size: 12px; }
@media (max-width: 920px) { .landing-ref-grid { grid-template-columns: 1fr; } }

.landing-section { max-width: 1180px; margin: 0 auto; padding: 72px 46px; }
.landing-section-head h2 { font-size: clamp(26px, 3vw, 32px); color: var(--ink); max-width: 560px; }
.landing-section-head p { max-width: 460px; margin-top: 8px; color: var(--ink-soft); font-size: 14px; line-height: 1.6; }
.landing-head-split { display: flex; justify-content: space-between; align-items: flex-end; gap: 32px; flex-wrap: wrap; }

.landing-card-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; margin-top: 36px; }
.landing-card-row.cols-4 { grid-template-columns: repeat(4, 1fr); }
.landing-mini-card { padding-top: 18px; border-top: 1px solid var(--line); }
.landing-mini-card strong { display: block; font-size: 15px; font-weight: 600; color: var(--ink); }
.landing-mini-card p { margin-top: 8px; color: var(--ink-soft); font-size: 13px; line-height: 1.55; }

.landing-dark-band { background: var(--dark-ink); color: #fff; }
.landing-dark-band .landing-section-head h2 { color: #fff; }
.landing-dark-band .landing-section-head p { color: var(--dark-ink-soft); }
.landing-dark-band .landing-mini-card { border-top-color: var(--dark-line); }
.landing-dark-band .landing-mini-card strong { color: #fff; }
.landing-dark-band .landing-mini-card p { color: var(--dark-ink-soft); }
.landing-step-num { font-family: "Lora", Georgia, serif; color: var(--dark-ink-soft); font-size: 26px; opacity: .55; }

.landing-split { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.landing-perm-card { padding: 22px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); box-shadow: var(--shadow-soft); }
.landing-perm-card header { padding-bottom: 14px; margin-bottom: 6px; border-bottom: 1px solid var(--line); font-size: 12px; font-weight: 600; color: var(--ink-soft); }
.landing-perm-row { display: flex; align-items: center; justify-content: space-between; padding: 12px 0; border-bottom: 1px solid var(--line-soft); font-size: 13px; color: var(--ink); }
.landing-perm-row:last-child { border-bottom: 0; }
.landing-pill-tag { padding: 3px 9px; border-radius: 999px; font-size: 10.5px; font-weight: 700; }
.landing-pill-tag.ok { color: var(--ok); background: var(--ok-pale); }
.landing-pill-tag.blocked { color: var(--danger); background: var(--danger-pale); }

.landing-mail-card { padding: 22px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); box-shadow: var(--shadow-soft); }
.landing-mail-from { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-bottom: 14px; border-bottom: 1px solid var(--line); font-size: 13px; font-weight: 600; color: var(--ink); }
.landing-mail-tag { padding: 3px 9px; border-radius: 999px; color: var(--warn); background: var(--warn-pale); font-size: 10.5px; font-weight: 700; white-space: nowrap; }
.landing-mail-quote { margin-top: 14px; color: var(--ink-soft); font-size: 13px; line-height: 1.55; font-style: italic; }
.landing-mail-draft-label { display: flex; align-items: center; gap: 6px; margin-top: 16px; color: var(--ink-faint); font-size: 11px; font-weight: 600; }
.landing-mail-draft { margin-top: 8px; padding: 14px; border-radius: 10px; background: var(--paper); color: var(--ink); font-size: 13px; line-height: 1.55; }
.landing-mail-chips { display: flex; gap: 8px; margin-top: 10px; }
.landing-mail-chips span { padding: 3px 9px; border: 1px solid var(--line); border-radius: 999px; font-size: 10.5px; color: var(--ink-soft); }
.landing-mail-actions { display: flex; gap: 10px; margin-top: 14px; }

.landing-pill-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 36px; }
.landing-int-pill { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 11px 16px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); font-size: 13px; font-weight: 600; color: var(--ink); }
.landing-int-pill .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); flex: 0 0 7px; }
.landing-int-pill-left { display: flex; align-items: center; gap: 10px; min-width: 0; }
.landing-int-pill-left img { width: 22px; height: 22px; object-fit: contain; border-radius: 5px; flex: 0 0 22px; }
.landing-int-pill-glyph { display: grid; place-items: center; width: 22px; height: 22px; flex: 0 0 22px; border-radius: 5px; color: var(--ink-faint); background: var(--line-soft); }
.landing-int-pill-glyph svg { width: 13px; height: 13px; }

.landing-pricing-head { text-align: center; max-width: 520px; margin: 0 auto; }
.landing-pricing-head h2 { font-size: clamp(26px, 3vw, 32px); }
.landing-pricing-head p { margin-top: 10px; color: var(--ink-soft); font-size: 14px; }
.landing-pricing-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 40px; align-items: stretch; }
.landing-price-card { position: relative; display: flex; flex-direction: column; padding: 28px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); }
.landing-price-card.is-featured { border-color: var(--ink); box-shadow: var(--shadow-lift); }
.landing-price-badge { position: absolute; top: -12px; left: 28px; padding: 4px 11px; border-radius: 999px; color: #fff; background: var(--dark-ink); font-size: 10.5px; font-weight: 700; }
.landing-price-card h3 { font-size: 19px; color: var(--ink); }
.landing-price-card .landing-price-from { margin-top: 14px; color: var(--ink-faint); font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }
.landing-price-amount { display: flex; align-items: baseline; gap: 4px; margin-top: 4px; }
.landing-price-amount .currency { color: var(--ink-soft); font-size: 15px; font-weight: 600; }
.landing-price-amount strong { font-family: "Lora", Georgia, serif; font-size: 34px; font-weight: 600; color: var(--ink); }
.landing-price-amount .period { color: var(--ink-faint); font-size: 12px; }
.landing-price-card > p { margin-top: 10px; color: var(--ink-soft); font-size: 13px; line-height: 1.5; min-height: 40px; }
.landing-price-list { display: flex; flex-direction: column; gap: 10px; margin-top: 16px; flex: 1; }
.landing-price-list li { display: flex; align-items: flex-start; gap: 8px; color: var(--ink-soft); font-size: 12.5px; line-height: 1.5; list-style: none; }
.landing-price-list svg { width: 13px; height: 13px; color: var(--ok); flex: 0 0 13px; margin-top: 2px; }
.landing-price-card .btn-secondary, .landing-price-card .btn-dark-pill { justify-content: center; width: 100%; margin-top: 20px; border-radius: 10px; }

.landing-faq-head { max-width: 280px; }
.landing-faq-head h2 { font-size: clamp(24px, 3vw, 30px); }
.landing-faq-list { display: flex; flex-direction: column; gap: 22px; }
.landing-faq-item { padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.landing-faq-item:last-child { border-bottom: 0; padding-bottom: 0; }
.landing-faq-item strong { display: block; font-size: 14.5px; font-weight: 600; color: var(--ink); }
.landing-faq-item p { margin-top: 6px; color: var(--ink-soft); font-size: 13px; line-height: 1.6; }

.landing-final-cta { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 72px 46px; background: var(--paper); border-top: 1px solid var(--line); }
.landing-final-cta h2 { font-size: clamp(26px, 3vw, 34px); max-width: 560px; }
.landing-final-cta div { margin-top: 24px; }

.landing-site-footer { padding: 40px 46px; background: var(--surface); border-top: 1px solid var(--line); }
.landing-footer-top { display: flex; align-items: center; justify-content: space-between; gap: 24px; max-width: 1180px; margin: 0 auto; }
.landing-footer-top .brand-logo-full { height: 28px; }
.landing-footer-links { display: flex; gap: 24px; }
.landing-footer-links a { color: var(--ink-soft); font-size: 13px; font-weight: 500; text-decoration: none; }
.landing-footer-links a:hover { color: var(--ink); }

@media (max-width: 760px) {
  .landing-footer-top { flex-direction: column; align-items: flex-start; gap: 14px; }
}

@media (max-width: 900px) {
  .landing-hero { grid-template-columns: 1fr; padding: 48px 24px; }
  .landing-split { grid-template-columns: 1fr; gap: 32px; }
  .landing-card-row, .landing-card-row.cols-4, .landing-pricing-row { grid-template-columns: 1fr; }
  .landing-pill-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  .landing-topbar { padding: 16px 20px; }
  .landing-nav-links { display: none; }
  .landing-section { padding: 48px 24px; }
}

@media (max-width: 980px) {
  .app-shell { --sidebar-w: 210px; }
  .topbar, .content-wrap { padding-left: 28px; padding-right: 28px; }
  .app-footer { padding-left: 28px; padding-right: 28px; }
  .brief-top { flex-wrap: wrap; } .hero-cta { align-self: center; }
}
@media (max-width: 760px) {
  .app-shell { display: block; }
  .app-footer { padding: 16px 20px; }
  .app-shell::before { display: none; }
  .sidebar { position: sticky; top: 0; z-index: 5; display: block; align-self: auto; height: auto; overflow: visible; min-height: auto; padding: 13px 16px; background: var(--sidebar-bg); border-right: 0; border-bottom: 1px solid var(--sidebar-line); }
  .sidebar-top { display: inline-flex; padding: 0; } .brand-logo-full { height: 26px; }
  .workspace-switcher, .sidebar-bottom, .nav-section-toggle, .nav-section-spaced { display: none; }
  /* Grupos viram transparentes no layout pra sobrar só a fileira de ícones (igual antes de existirem). */
  .nav-group, .nav-group-items { display: contents !important; }
  .main-nav { position: absolute; top: 13px; right: 16px; display: flex; flex: none; flex-direction: row; gap: 4px; margin: 0; padding: 0; overflow: visible; }
  .nav-item { display: none; min-height: 28px; width: 34px; padding: 5px; justify-content: center; } .nav-item.is-active { display: flex; } .nav-item span:not(.nav-icon) { display: none; }
  .topbar { height: 62px; padding: 0 18px; } .search-button kbd { display: none; } .topbar-actions { gap: 13px; } .search-button { padding: 7px 9px; } .topbar-user { display: none; }
  .content-wrap { padding: 33px 18px 20px; } .page-heading { display: block; } .page-heading .outline-button { margin-top: 20px; } .brief-band { padding: 22px 20px; } .brief-top { flex-wrap: wrap; } .hero-cta { margin-top: 10px; margin-left: 0; }
  .hero-stats { flex-wrap: wrap; gap: 14px 0; } .hero-stat { flex: 0 0 50%; border-left: 0; padding: 0; }
  .section-note { max-width: 120px; text-align: right; line-height: 1.4; } .insights-grid, .insights-grid-secondary { grid-template-columns: 1fr; } .panel { min-height: auto; } .territory-visual { height: 182px; }
}
@media (max-width: 420px) {
  h1 { font-size: 28px; } .topbar .breadcrumbs span, .topbar .breadcrumbs b { display: none; } .content-wrap { padding-top: 27px; } .brief-copy h2 { font-size: 18px; } .brief-copy p { font-size: 12px; } .metric-label { font-size: 9px; }
}

/* ---- Inbox conversation panel ---- */
.inbox-detail-pane { display: flex; flex-direction: column; }
.inbox-detail-title span { flex-wrap: wrap; }
.inbox-controls { display: flex; flex-wrap: wrap; gap: 18px; padding: 14px 24px; border-bottom: 1px solid var(--line-soft); }
.inbox-control { display: flex; flex-direction: column; gap: 6px; min-width: 180px; }
.inbox-control > span { color: var(--ink-faint); font-size: 10px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.inbox-control-ai > div { display: flex; align-items: center; gap: 8px; }
.btn-small { height: 30px; padding: 0 12px; font-size: 12px; }
.inbox-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 10px 24px; border-bottom: 1px solid var(--line-soft); }
.inbox-tags-label { margin-right: 4px; color: var(--ink-faint); font-size: 10px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.tag-chip { display: inline-flex; align-items: center; gap: 4px; padding: 3px 4px 3px 9px; border-radius: 999px; background: var(--line-soft); color: var(--ink); font-size: 11px; font-weight: 600; }
.tag-chip button { display: grid; place-items: center; width: 16px; height: 16px; border: 0; border-radius: 50%; background: transparent; color: var(--ink-faint); font-size: 13px; line-height: 1; }
.tag-chip button:hover { background: var(--line); color: var(--ink); }
.inbox-tags input { width: 110px; padding: 4px 8px; border: 1px dashed var(--line); border-radius: 999px; background: transparent; color: var(--ink); font-size: 11px; }
.inbox-tags input:focus { outline: none; border-style: solid; border-color: var(--dark-ink); }
.inbox-tabs { display: flex; gap: 4px; padding: 0 24px; border-bottom: 1px solid var(--line); }
.inbox-tabs button { padding: 10px 12px; border: 0; border-bottom: 2px solid transparent; background: transparent; color: var(--ink-soft); font-size: 12.5px; font-weight: 600; }
.inbox-tabs button.is-active { border-bottom-color: var(--dark-ink); color: var(--ink); }
.inbox-detail-body { display: flex; flex: 1; flex-direction: column; min-height: 0; }
.inbox-thread { flex: 1; min-height: 220px; max-height: 360px; padding: 16px 24px; overflow-y: auto; background: var(--paper); }
.inbox-thread-empty { padding: 28px 12px; color: var(--ink-faint); font-size: 12px; text-align: center; }
.msg { display: flex; flex-direction: column; max-width: 78%; margin-bottom: 12px; }
.msg-in { align-items: flex-start; }
.msg-out { align-items: flex-end; margin-left: auto; }
.msg-bubble { padding: 9px 12px; border-radius: 14px; font-size: 13px; line-height: 1.45; word-break: break-word; }
.msg-in .msg-bubble { border: 1px solid var(--line); border-top-left-radius: 4px; background: var(--surface); color: var(--ink); }
.msg-out .msg-bubble { border-top-right-radius: 4px; background: var(--dark-ink); color: #fff; }
.msg-ai .msg-bubble { background: var(--line); color: var(--ink); }
.msg-failed .msg-bubble { background: var(--danger-pale); border: 1px solid var(--danger-line); color: var(--danger); }
.msg-meta { margin-top: 4px; color: var(--ink-faint); font-size: 10px; }
.inbox-composer { display: flex; align-items: flex-end; gap: 10px; padding: 14px 24px; border-top: 1px solid var(--line); background: var(--surface); }
.inbox-composer textarea { flex: 1; min-height: 40px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); color: var(--ink); font: inherit; font-size: 13px; resize: vertical; }
.inbox-composer textarea:focus { outline: none; border-color: var(--dark-ink); }
.inbox-composer .btn-create { height: 40px; }
.inbox-notes { flex: 1; min-height: 220px; max-height: 360px; padding: 16px 24px; overflow-y: auto; background: var(--paper); }
.inbox-note { margin-bottom: 10px; padding: 10px 12px; border: 1px solid var(--warn-line); border-radius: 10px; background: var(--warn-pale); }
.inbox-note p { color: var(--ink); font-size: 12.5px; line-height: 1.45; }
.inbox-note span { display: block; margin-top: 5px; color: var(--ink-faint); font-size: 10px; }
.inbox-row-tag { margin-left: auto; padding: 1px 7px; border-radius: 999px; background: var(--line-soft); color: var(--ink-soft); font-size: 9.5px; font-weight: 600; }
.inbox-row-name { display: flex; align-items: center; gap: 7px; min-width: 0; }
.inbox-risk-dot { flex: 0 0 8px; width: 8px; height: 8px; border-radius: 50%; background: var(--ink-faint); }
.inbox-risk-dot.risk-high { background: var(--danger); }
.inbox-risk-dot.risk-medium { background: var(--warn); }
.inbox-risk-dot.risk-low { background: var(--ok); }
.inbox-row-meta { display: flex; align-items: center; gap: 4px; margin-top: 4px; color: var(--ink-faint); font-size: 10px; }
.inbox-row-meta svg { width: 11px; height: 11px; }

/* ---- Demand history ---- */
.history-list { margin: 0; padding: 0; list-style: none; }
.history-list li { padding: 8px 0 8px 14px; border-left: 2px solid var(--line); }
.history-list li strong { color: var(--ink); font-size: 12px; }
.history-list li span { margin-left: 6px; color: var(--ink-faint); font-size: 11px; }
.history-list li div { margin-top: 3px; color: var(--ink-soft); font-size: 12px; }

/* ---- Knowledge base ---- */
.knowledge-list { display: grid; gap: 12px; padding: 20px; }
.knowledge-card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.knowledge-card-head h3 { font-size: 14px; font-weight: 600; color: var(--ink); }
.knowledge-card p { margin-top: 8px; color: var(--ink-soft); font-size: 12.5px; line-height: 1.5; }
.knowledge-card-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-top: 12px; color: var(--ink-faint); font-size: 11px; }
.knowledge-actions { display: flex; gap: 14px; }

/* ---- Users, audit, settings ---- */
.user-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.role-legend { padding: 14px 20px; border-top: 1px solid var(--line); color: var(--ink-faint); font-size: 11.5px; line-height: 1.6; }
.role-legend strong { color: var(--ink-soft); }
code.secret { padding: 4px 8px; border-radius: 6px; background: var(--line-soft); color: var(--ink); font-size: 13px; user-select: all; }
.audit-details { max-width: 340px; color: var(--ink-faint); font-size: 11.5px; word-break: break-word; }
.settings-grid { display: grid; gap: 16px; max-width: 760px; }
.settings-card { padding: 20px 22px; }
.settings-card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; }
.settings-card h3 { font-size: 15px; font-weight: 600; color: var(--ink); }
.settings-card p { max-width: 560px; margin-top: 6px; color: var(--ink-soft); font-size: 12.5px; line-height: 1.55; }
.settings-note { margin-top: 12px !important; color: var(--ink-faint) !important; font-size: 11.5px !important; }
.settings-inline { display: flex; align-items: center; gap: 10px; margin-top: 14px; }
.settings-inline label { color: var(--ink-faint); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.settings-inline .field-input { width: 110px; }
.settings-card .btn-secondary { margin-top: 14px; }
.metric-item .metric-context { display: block; margin-top: 4px; color: var(--ink-faint); font-size: 10px; }

.main-nav::-webkit-scrollbar { width: 6px; }
.main-nav::-webkit-scrollbar-thumb { border-radius: 999px; background: var(--line); }

.automation-card-actions { display: flex; gap: 14px; }
.automation-remove { color: var(--danger); }
.automation-channel-tag { padding: 2px 9px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink-soft); font-size: 10.5px; font-weight: 600; }
.automation-tags { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.automation-audience-tag { padding: 2px 9px; border-radius: 999px; font-size: 10.5px; font-weight: 700; background: var(--brand-50); color: var(--brand-700); }
.automation-audience-tag.is-citizen { background: #e7f7ee; color: #128c4b; }
.automation-default-tag { padding: 2px 9px; border-radius: 999px; font-size: 10.5px; font-weight: 600; background: var(--ink-wash, #eef1f6); color: var(--ink-faint); }

.inbox-row-list .empty-state { align-items: center; min-height: 0; padding: 40px 20px; text-align: center; }
.inbox-row-list .empty-state p { max-width: 240px; }
.inbox-row-list .empty-glyph { margin-bottom: 8px; }

.account-grid { display: grid; grid-template-columns: max-content 1fr; gap: 10px 20px; margin-top: 14px; align-items: center; }
.account-grid dt { color: var(--ink-faint); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.account-grid dd { color: var(--ink); font-size: 13px; }

.inbox-risk-filter { display: flex; gap: 6px; padding: 0 16px 12px; }
.inbox-risk-chip { flex: 1; padding: 5px 4px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--ink-soft); font-size: 11px; font-weight: 600; }
.inbox-risk-chip:hover { border-color: var(--ink-faint); }
.inbox-risk-chip.is-active { color: #fff; background: var(--dark-ink); border-color: var(--dark-ink); }
.inbox-risk-chip.risk-high.is-active { background: var(--danger); border-color: var(--danger); }
.inbox-risk-chip.risk-medium.is-active { background: var(--warn); border-color: var(--warn); }
.inbox-risk-chip.risk-low.is-active { background: var(--ok); border-color: var(--ok); }

.notification-wrap { position: relative; }
.notification-menu { position: absolute; top: calc(100% + 10px); right: 0; z-index: 30; width: 320px; padding: 6px; border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--surface); box-shadow: var(--shadow-lift); }
.notification-menu[hidden] { display: none; }
.notification-menu-head { padding: 10px 10px 8px; color: var(--ink-faint); font-size: 10px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; border-bottom: 1px solid var(--line); }
.notification-menu-list { padding-top: 4px; max-height: 360px; overflow-y: auto; }
.notification-item { display: flex; align-items: flex-start; gap: 11px; width: 100%; padding: 10px; border: 0; border-radius: 9px; background: transparent; text-align: left; }
.notification-item:hover { background: var(--line-soft); }
.notification-item-icon { display: grid; place-items: center; flex: 0 0 32px; width: 32px; height: 32px; border-radius: 9px; }
.notification-item-icon svg { width: 16px; height: 16px; }
.notification-item-icon.notif-sla { color: var(--danger); background: var(--danger-pale); }
.notification-item-icon.notif-unassigned { color: var(--warn); background: var(--warn-pale); }
.notification-item-icon.notif-incident { color: var(--danger); background: var(--danger-pale); }
.notification-item-icon.notif-risk { color: var(--brand-700); background: var(--brand-50); }
.notification-item-body { min-width: 0; }
.notification-item-body strong { display: block; color: var(--ink); font-size: 13px; font-weight: 600; }
.notification-item-body span { display: block; margin-top: 2px; color: var(--ink-faint); font-size: 11.5px; }
.notification-empty { padding: 24px 12px; color: var(--ink-faint); font-size: 12.5px; text-align: center; }

@media (max-width: 860px) {
  .app-shell { grid-template-columns: 1fr; }
  .app-shell::before { display: none; }
  .sidebar { transform: translateX(-100%); transition: transform .22s ease; box-shadow: 0 0 40px rgba(0, 0, 0, .18); z-index: 40; }
  .sidebar.is-open { transform: translateX(0); }
  .main-content { grid-column: 1; }
  .app-footer { margin-left: 0; }
  .sidebar-toggle { display: inline-flex; }
  .topbar { padding: 0 16px; }
  .main-content > * { padding-left: 20px; padding-right: 20px; }
}

.table-head-actions { display: inline-flex; gap: 10px; align-items: center; }

/* Print / PDF for the reports view */
@media print {
  body.printing-report .sidebar,
  body.printing-report .topbar,
  body.printing-report .app-footer,
  body.printing-report #sidebar-backdrop,
  body.printing-report .reports-period,
  body.printing-report .page-heading > button { display: none !important; }
  body.printing-report .main-content { padding: 0 !important; grid-column: 1 / -1 !important; }
  body.printing-report .app-shell { display: block; }
  body.printing-report #list-view { box-shadow: none; }
  body.printing-report .table-card, body.printing-report .stat-tile { break-inside: avoid; box-shadow: none; }
  body.printing-report { background: #fff; }

  body.printing-etiquetas .sidebar,
  body.printing-etiquetas .topbar,
  body.printing-etiquetas .app-footer,
  body.printing-etiquetas #sidebar-backdrop,
  body.printing-etiquetas .page-heading,
  body.printing-etiquetas .etiquetas-filters,
  body.printing-etiquetas .table-card-head { display: none !important; }
  body.printing-etiquetas .main-content { padding: 0 !important; grid-column: 1 / -1 !important; }
  body.printing-etiquetas .app-shell { display: block; }
  body.printing-etiquetas .table-card { border: 0; box-shadow: none; }
  body.printing-etiquetas { background: #fff; }
  body.printing-etiquetas .etiquetas-grid { grid-template-columns: repeat(3, 1fr); }
  body.printing-etiquetas .etiqueta-label { break-inside: avoid; }
}

/* Etiquetas para Correios */
.etiquetas-filters { display: flex; flex-direction: column; gap: 14px; }
.etiquetas-filter-group { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; }
.etiquetas-filter-label { color: var(--ink-faint); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.etiquetas-check { display: inline-flex; align-items: center; gap: 6px; color: var(--ink-soft); font-size: 12.5px; font-weight: 500; }
.etiquetas-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.etiqueta-label { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border: 1px dashed var(--line); border-radius: 8px; min-height: 72px; }
.etiqueta-label strong { color: var(--ink); font-size: 12px; font-weight: 700; }
.etiqueta-label span { color: var(--ink-soft); font-size: 11px; line-height: 1.35; }
@media (max-width: 900px) { .etiquetas-grid { grid-template-columns: repeat(2, 1fr); } }

/* Árvore de indicações */
.arvore-tree { display: flex; flex-direction: column; gap: 4px; }
.arvore-node { margin-left: calc(var(--arvore-depth, 0) * 20px); }
.arvore-node-toggle { display: flex; align-items: center; gap: 8px; width: 100%; padding: 8px 10px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); color: inherit; font: inherit; text-align: left; cursor: pointer; }
.arvore-node-toggle:disabled { cursor: default; opacity: .85; }
.arvore-node-toggle:not(:disabled):hover { border-color: var(--brand-200); }
.arvore-node-caret { flex: 0 0 10px; color: var(--ink-faint); font-size: 10px; }
.arvore-node-name { flex: 1; min-width: 0; overflow: hidden; color: var(--ink); font-size: 12.5px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.arvore-node-count { flex: 0 0 auto; color: var(--ink-faint); font-size: 11px; }
.arvore-children { display: flex; flex-direction: column; gap: 4px; margin-top: 4px; }

/* Field visits (roteiro de campo) */
.visit-list { display: flex; flex-direction: column; }
.visit-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; padding: 14px 20px; border-top: 1px solid var(--line-soft); }
.visit-row-main strong { display: block; color: var(--ink); font-size: 13px; }
.visit-row-main span { color: var(--ink-faint); font-size: 11.5px; }
.visit-note { margin: 6px 0 0; color: var(--ink-soft); font-size: 12.5px; }

/* Referral (liderança) ranking */
.referral-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.referral-card { padding: 12px 14px; border: 1px solid var(--line-soft); border-radius: 12px; background: var(--surface); }
.referral-card-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.referral-card-head strong { font-size: 13px; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.referral-count { flex: 0 0 auto; padding: 2px 9px; border-radius: 999px; background: var(--brand-100); color: var(--brand-700); font-size: 12px; font-weight: 700; }
.referral-recent { display: block; color: var(--ink-faint); font-size: 11px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Goals ranking */
.goal-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.goal-card { padding: 14px; border: 1px solid var(--line-soft); border-radius: 12px; background: var(--surface); }
.goal-card.is-hit { border-color: var(--ok); background: var(--ok-pale); }
.goal-card-head { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.goal-rank { font-size: 16px; }
.goal-card-head strong { flex: 1; font-size: 13px; color: var(--ink); }
.goal-progress { display: flex; align-items: center; gap: 10px; }
.goal-progress .bar-track { flex: 1; }
.goal-progress span { font-size: 11.5px; color: var(--ink-soft); font-weight: 600; white-space: nowrap; }
.user-goal-input { width: 72px; padding: 6px 8px; font-size: 12.5px; }

/* Surveys */
.survey-tabs { margin-bottom: 16px; }
.survey-layout { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 16px; align-items: start; }
@media (max-width: 1100px) { .survey-layout { grid-template-columns: 1fr; } }
.survey-option-row { display: flex; gap: 8px; align-items: center; padding: 4px 0; }
.survey-option-row.is-dragging { opacity: .4; }
.survey-option-row .field-input { flex: 1; }
.survey-option-row .icon-button { flex: 0 0 auto; color: var(--ink-faint); }
.survey-option-row .icon-button:hover { color: var(--danger); }
.survey-drag-handle { flex: 0 0 auto; color: var(--ink-faint); font-size: 14px; cursor: grab; letter-spacing: -1px; }
.survey-option-num { display: grid; flex: 0 0 22px; place-items: center; width: 22px; height: 22px; border-radius: 50%; color: var(--brand-700); background: var(--brand-100); font-size: 11px; font-weight: 700; }
.survey-settings { margin-top: 4px; padding-top: 14px; border-top: 1px solid var(--line-soft); display: flex; flex-direction: column; gap: 10px; }
.survey-settings strong { color: var(--ink); font-size: 12.5px; font-weight: 700; }
.survey-toggle-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; color: var(--ink-soft); font-size: 13px; }
.survey-toggle { position: relative; display: inline-block; flex: 0 0 auto; width: 36px; height: 20px; cursor: pointer; }
.survey-toggle input { position: absolute; inset: 0; margin: 0; opacity: 0; cursor: pointer; z-index: 1; }
.survey-toggle-track { position: absolute; inset: 0; border-radius: 999px; background: var(--line); transition: background .15s ease; }
.survey-toggle-track::before { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0, 0, 0, .25); transition: transform .15s ease; }
.survey-toggle input:checked + .survey-toggle-track { background: var(--brand-600); }
.survey-toggle input:checked + .survey-toggle-track::before { transform: translateX(16px); }
.survey-closes-field { margin: 0; }
.survey-preview-col { position: sticky; top: 16px; display: flex; flex-direction: column; gap: 12px; }
.survey-preview-card { padding-bottom: 18px; }
.survey-preview-sub { display: block; margin: -10px 0 14px; color: var(--ink-faint); font-size: 11.5px; }
.survey-preview-mock { padding: 16px; border: 1px solid var(--line); border-radius: 14px; background: var(--paper); }
.survey-preview-mock-head { display: flex; align-items: center; gap: 8px; padding-bottom: 12px; margin-bottom: 12px; border-bottom: 1px solid var(--line); }
.survey-preview-mock-head .inbox-row-avatar { background: var(--brand-600); color: #fff; }
.survey-preview-mock-head strong { font-size: 13px; color: var(--ink); }
.survey-preview-question { display: block; font-size: 16px; font-weight: 700; line-height: 1.3; color: var(--ink); }
.survey-preview-hint { display: block; margin-top: 4px; color: var(--ink-faint); font-size: 11.5px; }
.survey-preview-options { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; }
.survey-preview-option { display: flex; align-items: center; gap: 9px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 9px; color: var(--ink); font-size: 12.5px; background: var(--surface); }
.survey-preview-submit { width: 100%; justify-content: center; margin-top: 14px; }
.survey-preview-submit:disabled { opacity: 1; cursor: default; }
.survey-preview-note { display: block; margin-top: 10px; text-align: center; color: var(--ink-faint); font-size: 10.5px; }
.survey-share-tip { padding: 12px 16px; border: 1px solid var(--brand-100); border-radius: 12px; background: var(--brand-50); color: var(--ink-soft); font-size: 12px; }
.survey-share-tip strong { color: var(--brand-700); }
.survey-list { display: flex; flex-direction: column; gap: 14px; margin-top: 18px; }
.survey-card .table-card-head h3 { font-size: 14px; }
.survey-bars { display: flex; flex-direction: column; gap: 10px; }
.survey-bar-row { display: grid; grid-template-columns: 140px 1fr 40px 36px; align-items: center; gap: 10px; }
.survey-bar-label { font-size: 12.5px; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.survey-bar-pct { font-size: 11.5px; color: var(--ink-soft); font-weight: 600; text-align: right; }
.survey-bar-votes { font-size: 11px; color: var(--ink-faint); text-align: right; }
@media (max-width: 700px) { .survey-bar-row { grid-template-columns: 100px 1fr 32px 0; } .survey-bar-votes { display: none; } }

.election-candidate-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.election-candidate-card { display: flex; align-items: center; gap: 12px; padding: 10px; border: 1px solid var(--line); border-radius: 12px; }
.election-candidate-photo { flex: 0 0 48px; width: 48px; height: 48px; border-radius: 50%; object-fit: cover; background: var(--line-soft); }
.election-candidate-info { display: flex; flex-direction: column; gap: 4px; min-width: 0; flex: 1; }
.election-candidate-info strong { font-size: 13px; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.election-candidate-info span { font-size: 11px; color: var(--ink-faint); }
.election-candidate-info .survey-bar-pct { text-align: left; }

/* Demands view toggle + Kanban board */
.view-toggle { display: inline-flex; gap: 4px; padding: 3px; border: 1px solid var(--line); border-radius: 11px; background: var(--paper); }
a.btn-create, a.btn-secondary, a.btn-primary-action { text-decoration: none; }
.view-toggle-btn { padding: 8px 15px; border: 0; border-radius: 8px; color: var(--ink-soft); background: transparent; font-size: 12.5px; font-weight: 600; white-space: nowrap; cursor: pointer; transition: background .15s ease, color .15s ease; }
.view-toggle-btn:hover { color: var(--ink); background: var(--line-soft); }
.panel-tabs { display: inline-flex; width: fit-content; margin: -4px 0 14px; gap: 6px; padding: 0; border: 0; background: transparent; }
.view-toggle-btn.is-active, .view-toggle-btn.is-active:hover { color: #fff; background: var(--brand-600); }
.kanban { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; padding: 16px 20px; align-items: start; overflow-x: auto; }
.kanban--two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.kanban-col { background: var(--paper); border: 1px solid var(--line-soft); border-radius: 12px; min-height: 120px; transition: border-color .12s ease, background .12s ease; }
.kanban-col.is-over { border-color: var(--brand-600); background: var(--brand-50); }
.kanban-col-head { display: flex; align-items: center; justify-content: space-between; padding: 11px 12px; border-bottom: 1px solid var(--line-soft); color: var(--ink); font-size: 12px; font-weight: 700; }
.kanban-col-head span { color: var(--ink-faint); font-weight: 600; }
.kanban-col-body { display: flex; flex-direction: column; gap: 8px; padding: 10px; }
.kanban-empty { color: var(--line); font-size: 12px; text-align: center; padding: 6px 0; }
.kanban-card { display: flex; flex-direction: column; gap: 5px; padding: 10px 11px; border: 1px solid var(--line-soft); border-radius: 10px; background: var(--surface); cursor: pointer; box-shadow: none; }
.kanban-card:hover { border-color: var(--line); }
.kanban-card.is-dragging { opacity: .5; }
.kanban-card-top { display: flex; align-items: center; justify-content: space-between; gap: 6px; }
.kanban-proto { color: var(--ink-faint); font-size: 10px; font-variant-numeric: tabular-nums; }
.kanban-card strong { color: var(--ink); font-size: 12.5px; font-weight: 600; line-height: 1.3; }
.kanban-meta { color: var(--ink-faint); font-size: 10.5px; }
@media (max-width: 1100px) { .kanban { grid-template-columns: repeat(5, minmax(180px, 1fr)); } }

/* Consulta eleitoral nacional: filtros, destaque do candidato e ranking. */
.tse-card { margin-bottom: 16px; }
.tse-filters { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; padding: 16px 18px 4px; }
.tse-filters-actions { display: flex; justify-content: flex-end; gap: 10px; padding: 10px 18px 18px; }
.tse-erro { margin: 0 18px 16px; padding: 10px 12px; border-radius: 10px; background: var(--danger-pale); border: 1px solid var(--danger-line); color: var(--danger); font-size: 13px; }
.tse-destaque { display: grid; grid-template-columns: 72px minmax(0, 1fr) auto; gap: 16px; align-items: center; padding: 18px; border-top: 1px solid var(--line); }
.tse-destaque-compacto { border-top: none; }
.tse-destaque-foto { width: 72px; height: 96px; object-fit: cover; border-radius: 10px; background: var(--paper); }
.tse-destaque-foto.is-empty { visibility: hidden; }
.tse-destaque-info strong { display: block; font-size: 18px; font-weight: 700; color: var(--ink); }
.tse-destaque-info p { margin: 6px 0 0; color: var(--ink-soft); font-size: 13px; }
.tse-destaque-tags { display: flex; align-items: center; gap: 8px; margin-top: 6px; }
.tse-destaque-votos { text-align: right; }
.tse-destaque-votos strong { display: block; font-size: 26px; font-weight: 700; color: var(--ink); letter-spacing: -0.02em; }
.tse-destaque-votos span { color: var(--ink-soft); font-size: 12px; }
.tse-rank { display: flex; flex-direction: column; }
.tse-rank-row { display: grid; grid-template-columns: 28px 44px minmax(0, 1fr) 120px 150px; gap: 12px; align-items: center; padding: 12px 18px; border-top: 1px solid var(--line); }
.tse-rank-pos { color: var(--ink-faint); font-size: 12px; font-weight: 600; text-align: center; }
.tse-rank-foto { width: 44px; height: 58px; object-fit: cover; border-radius: 8px; background: var(--paper); }
.tse-rank-foto.is-empty { visibility: hidden; }
.tse-rank-main strong { display: block; font-size: 14px; font-weight: 600; color: var(--ink); }
.tse-rank-main span { color: var(--ink-soft); font-size: 12px; }
.tse-rank-main .bar-track { margin-top: 6px; }
.tse-rank-votos { text-align: right; }
.tse-rank-votos strong { display: block; font-size: 15px; font-weight: 700; color: var(--ink); }
.tse-rank-votos span { color: var(--ink-soft); font-size: 12px; }
.tse-rank-situacao { text-align: right; }
.tse-extrato-metricas { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; padding: 16px 18px; }
.tse-metric strong { display: block; }
.tse-metric { padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); }
.tse-metric span { display: block; color: var(--ink-soft); font-size: 12px; }
.tse-metric strong { font-size: 20px; font-weight: 700; color: var(--ink); letter-spacing: -0.02em; }
.tse-chips { display: flex; flex-wrap: wrap; gap: 8px; padding: 12px 18px; border-top: 1px solid var(--line); }
.tse-chip { padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--ink-soft); font-size: 12px; font-weight: 600; cursor: pointer; }
.tse-chip:hover { border-color: var(--brand-400); color: var(--brand-700); }
.tse-chip.is-active { background: var(--brand-600); border-color: var(--brand-600); color: #fff; }
@media (max-width: 1100px) {
  .tse-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tse-rank-row { grid-template-columns: 24px 40px minmax(0, 1fr) 100px; }
  .tse-rank-situacao { grid-column: 3 / -1; text-align: left; }
}
@media (max-width: 720px) {
  .tse-filters, .tse-extrato-metricas { grid-template-columns: 1fr; }
  .tse-destaque { grid-template-columns: 56px minmax(0, 1fr); }
  .tse-destaque-votos { grid-column: 1 / -1; text-align: left; }
}

/* Editor de acesso por usuário: um módulo por linha, com caixa de seleção. */
.perm-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 18px; }
.perm-row { display: flex; align-items: center; gap: 8px; color: var(--ink); font-size: 13px; font-weight: 500; cursor: pointer; }
.perm-row input { accent-color: var(--brand-600); }
@media (max-width: 820px) { .perm-grid { grid-template-columns: 1fr; } }

/* Comparar eleições: dois recortes lado a lado e a variação entre eles. */
.comparar-card .table-card-head { align-items: flex-start; gap: 12px; }
.comparar-card .donut-wrap { align-items: flex-start; }
.comparar-card .table-card-head .filter-select { max-width: 260px; }
.comparar-tag { display: inline-block; margin-bottom: 6px; padding: 2px 8px; border-radius: 999px; background: var(--brand-50); color: var(--brand-700); font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.comparar-resumo { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; padding: 14px 18px; border-top: 1px solid var(--line); }
.comparar-resumo span { display: block; color: var(--ink-soft); font-size: 12px; }
.comparar-resumo strong { font-size: 18px; font-weight: 700; color: var(--ink); letter-spacing: -0.01em; }
.comparar-tabela td.num, .comparar-tabela th.num { text-align: right; white-space: nowrap; }
.comparar-tabela td.muted { color: var(--ink-soft); }
.comparar-delta { min-width: 150px; }
.comparar-delta span { display: block; font-size: 13px; font-weight: 700; }
.comparar-delta i { display: block; height: 4px; margin-top: 4px; border-radius: 999px; background: currentColor; opacity: .5; }
.comparar-tabela td.comparar-delta--sobe { color: var(--ok); }
.comparar-tabela td.comparar-delta--desce { color: var(--danger); }
.comparar-tabela td.comparar-delta--igual { color: var(--ink-faint); }
.comparar-tabela td.comparar-delta span { color: inherit; }
@media (max-width: 900px) { .comparar-resumo { grid-template-columns: 1fr 1fr; } .comparar-card .table-card-head .filter-select { max-width: 100%; } }

/* Zona de fogo no mapa do território: botão de ligar e desligar, mais a escala. */
.territory-heat-btn { position: absolute; top: 12px; right: 12px; z-index: 501; display: inline-flex; align-items: center; gap: 7px; margin-right: 150px; padding: 7px 13px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); box-shadow: var(--shadow-card); color: var(--ink-soft); font-size: 12.5px; font-weight: 600; cursor: pointer; }
.territory-heat-btn svg { width: 15px; height: 15px; }
.territory-heat-btn:hover { border-color: var(--brand-400); color: var(--brand-700); }
.territory-heat-btn.is-active { background: var(--brand-600); border-color: var(--brand-600); color: #fff; }
.territory-heat-legend { position: absolute; bottom: 12px; right: 12px; z-index: 500; padding: 10px 14px; border-radius: 10px; background: rgba(255, 255, 255, .95); box-shadow: var(--shadow-card); font-size: 11.5px; }
.territory-heat-legend strong { display: block; margin-bottom: 6px; color: var(--ink); font-size: 11px; letter-spacing: .04em; text-transform: uppercase; }
.territory-heat-scale { display: block; width: 150px; height: 8px; border-radius: 999px; background: linear-gradient(90deg, #2BA98B, #E8C53F, #E8902F, #D0453B); }
.territory-heat-ends { display: flex; justify-content: space-between; width: 150px; margin-top: 5px; color: var(--ink-soft); }
.territory-heat-ends em { font-style: normal; font-size: 10.5px; }
@media (max-width: 760px) {
  .territory-heat-btn { top: 56px; right: 12px; margin-right: 0; }
  .territory-heat-legend { position: static; margin: 10px 0 0; box-shadow: none; background: transparent; padding: 0; }
}

/* Respiro extra: a primeira e a última coluna não encostam na borda do card, e
   cards irmãos param de ficar colados. */
.data-table th:first-child, .data-table td:first-child { padding-left: 24px; }
.data-table th:last-child, .data-table td:last-child { padding-right: 24px; }
.table-card + .table-card { margin-top: 18px; }
.chart-body { padding: 20px 24px 24px; }

/* Resumo da página dentro do próprio card, no padrão do extrato financeiro:
   números grandes em faixa, separados por divisória fina. */
.page-card-head-actions { display: flex; align-items: center; gap: 10px; }
.summary-strip { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 14px; padding: 20px 26px 26px; border-bottom: 1px solid var(--line); }
.summary-cell { padding: 16px 18px; border-radius: var(--radius-md); background: var(--paper); transition: box-shadow .15s var(--ease), transform .15s var(--ease); }
.summary-cell:hover { box-shadow: var(--shadow-card); transform: translateY(-1px); }
.summary-cell span { display: block; color: var(--ink-soft); font-size: 13px; }
.summary-cell strong { display: block; margin-top: 6px; font-size: 26px; font-weight: 700; letter-spacing: -0.02em; color: var(--ink); font-variant-numeric: tabular-nums; }
.summary-cell--brand { background: var(--brand-50); }
.summary-cell--brand strong { color: var(--brand-700); }
.summary-cell--danger { background: var(--danger-pale); }
.summary-cell--danger strong { color: var(--danger); }
.summary-cell--warn { background: var(--warn-pale); }
.summary-cell--warn strong { color: var(--warn); }
.summary-cell--ok { background: var(--ok-pale); }
.summary-cell--ok strong { color: var(--ok); }
.summary-cell em { display: block; margin-top: 4px; color: var(--ink-faint); font-size: 12px; font-style: normal; }
.page-card-section { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; padding: 22px 24px 0; }
.page-card-section h4 { font-size: 17px; font-weight: 700; letter-spacing: -0.01em; color: var(--ink); }
.page-card-section p { margin-top: 3px; color: var(--ink-soft); font-size: 13px; }
@media (max-width: 900px) {
  .summary-strip { grid-auto-flow: row; grid-template-columns: 1fr 1fr; gap: 12px; }
}
@media (max-width: 560px) {
  .summary-strip { grid-template-columns: 1fr; }
}
/* Depois do título da lista, a barra de filtros perde o fundo e encosta menos. */
.page-card-section + .table-toolbar { padding-top: 14px; border-top: none; background: transparent; }

/* Relatórios: abas por tema, barra de período e listas de barras horizontais. */
.reports-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; border-bottom: 1px solid var(--line); }
.reports-tab { display: inline-flex; align-items: center; gap: 9px; padding: 11px 18px; border: none; border-bottom: 2px solid transparent; background: transparent; color: var(--ink-soft); font-size: 14.5px; font-weight: 600; cursor: pointer; }
.reports-tab svg { width: 17px; height: 17px; }
.reports-tab:hover { color: var(--brand-700); }
.reports-tab.is-active { border-radius: 12px 12px 0 0; border-bottom-color: var(--brand-600); background: var(--brand-50); color: var(--brand-700); }
.reports-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 10px; }
.reports-period-label { margin-right: 4px; color: var(--ink-soft); font-size: 13px; font-weight: 600; }
.reports-export { display: flex; flex-wrap: wrap; gap: 8px; }
.reports-alert { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-bottom: 18px; padding: 16px 18px; border: 1px solid var(--danger-line); border-radius: 14px; background: var(--danger-pale); }
.reports-alert-ic { display: inline-flex; color: var(--danger); }
.reports-alert-ic svg { width: 22px; height: 22px; }
.reports-alert div { flex: 1; min-width: 220px; }
.reports-alert strong { display: block; color: var(--danger); font-size: 15px; }
.reports-alert span { color: var(--ink-soft); font-size: 13px; }
.report-bars { display: flex; flex-direction: column; gap: 14px; }
.report-bar-row { display: flex; align-items: center; gap: 12px; }
.report-bar-label { display: inline-flex; flex: 0 1 auto; min-width: 0; max-width: 170px; align-items: center; gap: 9px; color: var(--ink); font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.report-bar-label i { width: 9px; height: 9px; border-radius: 3px; flex: 0 0 9px; }
.report-bar-row .bar-track { flex: 1 1 70px; min-width: 48px; height: 8px; }
.report-bar-row .bar-fill { display: block; }
.report-bar-value { flex: 0 0 auto; margin-left: auto; text-align: right; color: var(--ink); font-size: 14px; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.report-bar-share { color: var(--ink-soft); font-weight: 500; }
.report-grid--three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.chart-foot { margin-top: 14px; color: var(--ink-faint); font-size: 12px; }
.productivity-grid th, .productivity-grid td { padding: 10px 12px; }
.productivity-grid th:first-child, .productivity-grid td:first-child { padding-left: 0; }
.productivity-grid th.num, .productivity-grid td.num { text-align: right; }
@media (max-width: 1100px) { .report-grid--three { grid-template-columns: 1fr; } }
@media (max-width: 700px) {
  .report-bar-row { flex-wrap: wrap; }
  .report-bar-label { flex: 1 1 auto; }
  .report-bar-row .bar-track { order: 3; flex: 1 1 100%; }
}

/* ============================================================
   Burple Gov — camada de redesenho
   Especificação vinda de: Primer (PageHeader), Atlassian (space/type),
   Carbon (data table, empty state), Polaris (pesos 450/550/650).
   ============================================================ */

:root {
  /* Escala de espaço 4px (Atlassian/Polaris) */
  --s1: 4px;  --s2: 8px;  --s3: 12px; --s4: 16px;
  --s5: 20px; --s6: 24px; --s7: 32px; --s8: 40px;

  /* Raio deliberado por tamanho de elemento — não um raio só pra tudo */
  --r-control: 4px;   /* input, botão, badge quadrado */
  --r-card: 6px;      /* card, tabela */
  --r-float: 10px;    /* modal, popover, drawer */

  /* Neutros: 90% da interface mora aqui */
  --ink: #16181D;
  --ink-soft: #5A6069;
  --ink-faint: #878D97;
  --line: #E3E5E9;
  --line-strong: #CFD3DA;
  --line-soft: #EEF0F3;
  --paper: #F7F8FA;
  --surface: #FFFFFF;
  --surface-sunken: #FAFBFC;

  /* Marca: roxo só em logo e ação primária. Fora disso, neutro. */
  --brand-600: #6A4FD0;
  --brand-700: #5A3FC0;
  --brand-50: #F3F0FD;

  /* Status: cor só carrega estado, nunca decora */
  --ok: #1F7A52;
  --ok-pale: #EAF5EF;
  --warn: #9A6212;
  --warn-pale: #FBF2E3;
  --danger: #B3261E;
  --danger-pale: #FBECEB;

  --radius-sm: var(--r-control);
  --radius-md: var(--r-card);
  --radius-lg: var(--r-float);

  font-size: 13px;
  font-feature-settings: "cv05" 1, "cv11" 1, "ss03" 1;
}

/* ---------- Tipografia: meio-passo 450/550/650 dá o ar "desenhado" ---------- */
body:has(> .app-shell) { font-size: 13px; line-height: 1.55; color: var(--ink); }
body:has(> .app-shell) h1,
body:has(> .app-shell) h2,
body:has(> .app-shell) h3,
body:has(> .app-shell) h4 { font-weight: 650; letter-spacing: -0.012em; }

/* ============================================================
   1. CABEÇALHO DE PÁGINA — faixa-superfície, não título solto
   Primer: a régua de 1px do header é suprimida quando há abas.
   ============================================================ */
.content-wrap { width: min(1320px, 100%); padding: 0 0 var(--s8); }

.page-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--s6);
  margin: 0 0 var(--s6);
  padding: var(--s5) var(--s7) var(--s5);
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}
.page-heading > div:first-child { min-width: 0; }
body:has(> .app-shell) h1 {
  font-size: 20px;
  line-height: 26px;
  font-weight: 650;
  letter-spacing: -0.015em;
  color: var(--ink);
  max-width: none;
  margin: 0;
}
.page-heading p {
  margin-top: var(--s1);
  color: var(--ink-soft);
  font-size: 13px;
  line-height: 18px;
  max-width: 68ch;
}
.page-heading-actions { gap: var(--s2); padding-top: 2px; }

/* Barra de controle de uma view, no lugar do antigo cabeçalho duplicado. */
.view-toolbar { display: flex; align-items: center; justify-content: flex-end; gap: var(--s2); margin-bottom: var(--s3); }

/* Conteúdo abaixo do header respira na mesma calha do header */
#list-view, #command-view { padding: 0 var(--s7); }

/* ============================================================
   2. CARD — borda, sem sombra; seções separadas por régua
   Carbon: hierarquia por camada ($layer-01 → $layer-02), não por sombra.
   ============================================================ */
.table-card,
.panel {
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  background: var(--surface);
  box-shadow: none;
}
.panel { padding: 0; min-height: 0; }
.panel-heading {
  margin: 0;
  padding: var(--s3) var(--s4);
  border-bottom: 1px solid var(--line-soft);
  gap: var(--s2);
}
/* Chip colorido em volta de todo ícone é tell de template: ícone inline, 14px, neutro */
.panel-heading > svg:first-child {
  width: 15px; height: 15px; padding: 0;
  border-radius: 0; background: none;
  color: var(--ink-faint);
  flex: 0 0 15px;
}
.panel h3 { font-size: 14px; line-height: 20px; font-weight: 600; }
.panel-subtitle { margin: 0; padding: var(--s3) var(--s4) 0; font-size: 12px; color: var(--ink-faint); }
.panel > .workload-list,
.panel > .today-panel-list,
.panel > .task-checklist,
.panel > .agenda-day-list,
.panel > .orcamento-list,
.panel > div[id$="-chart"],
.panel > .empty-state { padding: var(--s4); }

.table-card-head {
  padding: var(--s3) var(--s4);
  border-bottom: 1px solid var(--line-soft);
  min-height: 48px;
}
.table-card-head h3 { font-size: 14px; font-weight: 600; letter-spacing: -0.008em; }
.table-card-head p { margin-top: 2px; font-size: 12px; color: var(--ink-faint); }

.page-card-section {
  padding: var(--s3) var(--s4);
  border-bottom: 1px solid var(--line-soft);
  min-height: 48px;
}
.page-card-section h4 { font-size: 14px; line-height: 20px; font-weight: 600; letter-spacing: -0.008em; }
.page-card-section p { margin-top: 1px; font-size: 12px; color: var(--ink-faint); }
.page-card-section + .table-toolbar { padding: var(--s2) var(--s4); border-bottom: 1px solid var(--line-soft); }

/* ============================================================
   3. NÚMEROS — faixa de métricas: sem fundo colorido, sem chip
   Cor só no número quando o número é um estado.
   ============================================================ */
.summary-strip {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  gap: 0;
  padding: 0;
  border-bottom: 1px solid var(--line-soft);
}
.summary-cell {
  padding: var(--s4);
  border-radius: 0;
  background: transparent;
  border-right: 1px solid var(--line-soft);
}
.summary-cell:last-child { border-right: 0; }
.summary-cell:hover { box-shadow: none; transform: none; background: var(--surface-sunken); }
.summary-cell span {
  font-size: 11px;
  line-height: 16px;
  font-weight: 550;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-faint);
}
.summary-cell strong {
  margin-top: var(--s2);
  font-size: 26px;
  line-height: 30px;
  font-weight: 650;
  letter-spacing: -0.025em;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
}
.summary-cell em { margin-top: 2px; font-size: 12px; color: var(--ink-faint); }
/* Número de dinheiro não é alarme: o valor fica em tinta neutra e o tom vira
   uma régua de 2px no topo da célula. Vermelho só quando significa problema. */
.summary-cell--brand, .summary-cell--ok, .summary-cell--warn, .summary-cell--danger {
  background: transparent;
  box-shadow: inset 0 2px 0 var(--line-strong);
}
.summary-cell strong,
.summary-cell--brand strong,
.summary-cell--ok strong,
.summary-cell--warn strong,
.summary-cell--danger strong { color: var(--ink); }
.summary-cell--brand { box-shadow: inset 0 2px 0 var(--brand-600); }
.summary-cell--ok { box-shadow: inset 0 2px 0 var(--ok); }
.summary-cell--warn { box-shadow: inset 0 2px 0 var(--warn); }
.summary-cell--danger { box-shadow: inset 0 2px 0 var(--danger); }

/* Eyebrow do cabeçalho: diz em que seção você está, sem repetir o título */
.page-eyebrow {
  display: block;
  margin-bottom: var(--s1);
  font-size: 11px;
  line-height: 16px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

/* Stat tiles do dashboard: mesma lógica, régua de 2px à esquerda carrega a cor */
.stat-grid { gap: var(--s3); margin-bottom: var(--s6); }
.stat-tile {
  padding: var(--s4) var(--s4) var(--s4) calc(var(--s4) - 2px);
  border: 1px solid var(--line);
  border-left: 3px solid var(--line-strong);
  border-radius: var(--r-card);
  box-shadow: none;
}
.stat-tile:hover { box-shadow: none; transform: none; border-color: var(--line-strong); background: var(--surface-sunken); }
.stat-tile--brand { border-left-color: var(--brand-600); }
.stat-tile--ok { border-left-color: var(--ok); }
.stat-tile--warn { border-left-color: var(--warn); }
.stat-tile--danger { border-left-color: var(--danger); }
.stat-ic {
  top: var(--s4); right: var(--s4);
  width: 15px; height: 15px;
  background: none; border-radius: 0;
  color: var(--ink-faint);
}
.stat-ic svg { width: 15px; height: 15px; }
.stat-tile--brand .stat-ic, .stat-tile--ok .stat-ic { color: var(--ink-faint); }
.stat-tile--warn .stat-ic { color: var(--warn); }
.stat-tile--danger .stat-ic { color: var(--danger); }
.stat-body { padding-right: var(--s5); }
.stat-label {
  font-size: 11px; line-height: 16px; font-weight: 550;
  letter-spacing: 0.04em; text-transform: uppercase; color: var(--ink-faint);
}
.stat-tile strong {
  margin-top: var(--s2);
  font-size: 26px; line-height: 30px; font-weight: 650;
  letter-spacing: -0.025em; font-variant-numeric: tabular-nums; color: var(--ink);
}
.stat-tile--warn strong, .stat-tile--danger strong { color: var(--ink); }
.stat-ctx { margin-top: var(--s1); font-size: 12px; color: var(--ink-faint); }

/* ============================================================
   4. TABELA — densidade Carbon, cabeçalho sem caixa-alta
   ============================================================ */
table.data-table { font-size: 13px; }
.data-table thead { background: var(--surface-sunken); border-bottom: 1px solid var(--line); }
.data-table th {
  height: 40px;
  padding: 0 var(--s4);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
  color: var(--ink-soft);
  white-space: nowrap;
}
.data-table td {
  height: 44px;
  padding: var(--s2) var(--s4);
  font-size: 13px;
  line-height: 18px;
  color: var(--ink-soft);
  border-bottom: 1px solid var(--line-soft);
  vertical-align: middle;
}
.data-table tbody tr { box-shadow: inset 2px 0 0 transparent; transition: background .1s linear, box-shadow .1s linear; }
.data-table tbody tr:hover { background: var(--surface-sunken); box-shadow: inset 2px 0 0 var(--brand-600); }
.data-table tbody tr:hover td { background: transparent; color: var(--ink); }
.data-table .primary-cell { color: var(--ink); font-weight: 550; max-width: 420px; }
.data-table .muted-cell,
.data-table td span.muted-cell { font-size: 12px; color: var(--ink-faint); }
.money-cell { font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }

/* Protocolo/código: monoespaçado é afordância de domínio, não enfeite */
.doc-hash, .cell-sub-protocol { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 11.5px; }

.table-pager {
  padding: var(--s3) var(--s4);
  border-top: 1px solid var(--line-soft);
  font-size: 12px;
  color: var(--ink-faint);
}
.pager-button {
  height: 28px; padding: 0 var(--s3);
  border: 1px solid var(--line-strong); border-radius: var(--r-control);
  font-size: 12px; font-weight: 550; color: var(--ink-soft); background: var(--surface);
}
.pager-button:hover:not(:disabled) { background: var(--surface-sunken); border-color: var(--ink-faint); color: var(--ink); }
.pager-button:disabled { border-color: var(--line); color: var(--line-strong); }

/* ============================================================
   5. CONTROLES — alturas Primer (28/32), raio 4px
   ============================================================ */
.table-toolbar { gap: var(--s2); padding: var(--s2) var(--s4); background: transparent; border-bottom: 1px solid var(--line-soft); }
.filter-select,
.field-input, .field-select, .field-textarea {
  height: 32px; padding: 0 var(--s2);
  border: 1px solid var(--line-strong); border-radius: var(--r-control);
  font-size: 13px; color: var(--ink); background: var(--surface);
}
.field-textarea { height: auto; padding: var(--s2); }
.filter-select:focus, .field-input:focus, .field-select:focus, .field-textarea:focus {
  outline: 2px solid var(--brand-600); outline-offset: -1px; border-color: var(--brand-600); box-shadow: none;
}
.btn-create, .btn-primary-action, body:has(> .app-shell) .btn-primary-action {
  height: 32px; padding: 0 var(--s3);
  border-radius: var(--r-control);
  background: var(--brand-700); box-shadow: none;
  font-size: 13px; font-weight: 550; letter-spacing: 0;
}
.btn-create:hover { background: var(--brand-600); transform: none; }
.btn-secondary, .outline-button, .pager-button, .search-button {
  border-radius: var(--r-control); font-weight: 550;
}
.btn-secondary { height: 32px; border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink); font-size: 13px; }
.btn-secondary:hover { background: var(--surface-sunken); }

/* Badge: pílula só pra status; peso 550, sem borda dupla */
.badge {
  padding: 2px var(--s2);
  border-radius: var(--r-control);
  border: 0;
  font-size: 12px;
  font-weight: 550;
  letter-spacing: 0;
}
.badge-brand, .badge-neutral, .badge-outline { background: var(--line-soft); color: var(--ink-soft); }
.badge-ok { background: var(--ok-pale); color: var(--ok); }
.badge-warn { background: var(--warn-pale); color: var(--warn); }
.badge-danger { background: var(--danger-pale); color: var(--danger); }
.badge-solid { background: var(--ink); color: #fff; }

/* ============================================================
   6. VAZIO — Carbon: alinhado à esquerda, diz o escopo, oferece saída
   ============================================================ */
.empty-state, .empty-state-lg, .compact-empty {
  align-items: flex-start !important;
  text-align: left !important;
  min-height: 0;
  padding: var(--s6) var(--s4);
}
.empty-glyph { display: none !important; }
.empty-state strong { font-size: 13px; font-weight: 600; color: var(--ink); }
.empty-state p { margin-top: var(--s1); max-width: 52ch; font-size: 12px; line-height: 18px; color: var(--ink-faint); }
.compact-empty p { max-width: 52ch; }

/* ============================================================
   7. CHROME — topbar e sidebar mais quietas
   ============================================================ */
.topbar { height: 52px; padding: 0 var(--s7); border-bottom: 1px solid var(--line); }
.breadcrumbs { font-size: 12px; color: var(--ink-faint); }
.breadcrumbs strong { font-weight: 550; color: var(--ink-soft); }
.search-button {
  height: 28px; width: 240px; padding: 0 var(--s2);
  border: 1px solid var(--line); background: var(--surface-sunken);
  font-size: 12px; color: var(--ink-faint);
}
.topbar-user strong { font-size: 12px; font-weight: 550; }
.topbar-user span { font-size: 11px; }
.avatar { border-radius: var(--r-control); background: var(--line-soft); color: var(--ink-soft); font-size: 11px; font-weight: 600; }

.sidebar { padding: var(--s3) var(--s2) var(--s2); border-right: 1px solid var(--line); }
.app-shell { --sidebar-w: 236px; }
.nav-section-toggle { padding: var(--s3) var(--s2) var(--s1); }
.nav-section-label { font-size: 11px; font-weight: 600; letter-spacing: 0.04em; color: var(--ink-faint); }
.nav-item {
  min-height: 30px; padding: 0 var(--s2); gap: var(--s2);
  border-radius: var(--r-control);
  font-size: 13px; font-weight: 450; color: var(--ink-soft);
}
.nav-item:hover { background: var(--line-soft); color: var(--ink); }
.nav-item.is-active {
  background: var(--line-soft); color: var(--ink); font-weight: 600;
  box-shadow: inset 2px 0 0 var(--brand-600);
}
.nav-item.is-active .nav-icon { color: var(--brand-700); }
.nav-icon svg { width: 16px; height: 16px; }
.nav-count {
  padding: 0 5px; border-radius: var(--r-control);
  background: var(--line-soft); color: var(--ink-faint);
  font-size: 11px; font-weight: 600; font-variant-numeric: tabular-nums;
}
.nav-item.is-active .nav-count { background: var(--brand-50); color: var(--brand-700); }
.user-chip { padding: var(--s2); border: 1px solid var(--line); border-radius: var(--r-card); background: var(--surface); }
.brand-logo-full { height: 26px; }

/* ============================================================
   8. DETALHES DE OFÍCIO
   foco visível, hover sempre, números tabulares, régua única
   ============================================================ */
:focus-visible { outline: 2px solid var(--brand-600); outline-offset: 1px; }
.data-table td:has(> .money-cell), .money-head { text-align: right; }
.panel-count, .demands-tab-count {
  font-variant-numeric: tabular-nums; font-weight: 600;
  background: var(--line-soft); color: var(--ink-soft); border-radius: var(--r-control);
}

/* Abas: régua única embaixo, sem pílula sólida roxa */
.demands-tabs-row { padding: 0 var(--s4); border-bottom: 1px solid var(--line-soft); }
.demands-tabs { gap: 0; }
.demands-tab {
  height: 40px; padding: 0 var(--s3); border-radius: 0;
  border-bottom: 2px solid transparent;
  font-size: 13px; font-weight: 550; color: var(--ink-soft); background: transparent;
}
.demands-tab:hover { background: transparent; color: var(--ink); }
.demands-tab.is-active { background: transparent; color: var(--ink); border-bottom-color: var(--brand-600); }
.demands-tab.is-active .demands-tab-count { background: var(--brand-50); color: var(--brand-700); }
.view-toggle { padding: 2px; border: 1px solid var(--line); border-radius: var(--r-control); background: var(--surface-sunken); }
.view-toggle-btn { height: 26px; padding: 0 var(--s3); border-radius: 3px; font-size: 12px; font-weight: 550; }
.view-toggle-btn.is-active, .view-toggle-btn.is-active:hover { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(16,18,23,.08); }

/* Banner de IA: deixa de ser bloco roxo e vira nota com régua */
.ai-summary-banner {
  padding: var(--s3) var(--s4);
  border: 1px solid var(--line);
  border-left: 3px solid var(--brand-600);
  border-radius: var(--r-card);
  background: var(--surface);
}
.ai-summary-ic { width: 15px; height: 15px; border-radius: 0; background: none; color: var(--brand-700); }
.ai-summary-ic svg { width: 15px; height: 15px; }
.ai-summary-copy strong { font-size: 13px; font-weight: 600; }
.ai-summary-copy span { font-size: 13px; color: var(--ink-soft); }
.ai-summary-cta { height: 28px; padding: 0 var(--s3); border: 1px solid var(--line-strong); border-radius: var(--r-control); color: var(--ink); background: var(--surface); font-size: 12px; font-weight: 550; }

/* Kanban mais denso */
.kanban-card { padding: var(--s2) var(--s3); border: 1px solid var(--line); border-radius: var(--r-card); }
.kanban-col-head { font-size: 12px; font-weight: 600; color: var(--ink-soft); }

/* Rodapé do app, discreto */
.app-footer { padding: var(--s3) var(--s7); border-top: 1px solid var(--line); background: var(--surface); }
.app-footer-credit { font-size: 12px; }

/* ============================================================
   Sidebar enxuta: itens fixos no topo, grupos de um aberto por vez,
   e abas de página para as views que deixaram de ter item próprio.
   ============================================================ */
.sidebar-search {
  display: flex; align-items: center; gap: var(--s2);
  width: 100%; height: 30px; margin: 0 0 var(--s2);
  padding: 0 var(--s2);
  border: 1px solid var(--line); border-radius: var(--r-control);
  background: var(--surface-sunken); color: var(--ink-faint);
  font-size: 12px; text-align: left;
}
.sidebar-search:hover { border-color: var(--line-strong); color: var(--ink-soft); }
.sidebar-search svg { flex: 0 0 14px; width: 14px; height: 14px; }
.sidebar-search kbd { margin-left: auto; border: 0; background: none; color: var(--ink-faint); font-size: 10px; }

/* Topbar perde a busca duplicada: ela agora vive no topo da sidebar. */
.topbar .search-button { display: none; }

.sidebar-bottom { display: flex; flex-direction: column; gap: 2px; padding-top: var(--s2); border-top: 1px solid var(--line-soft); }
.sidebar-bottom .nav-item { min-height: 28px; }
.sidebar-bottom .user-chip { margin-top: var(--s2); }

/* Cabeçalho em coluna: título em cima, faixa de abas embaixo.
   Primer: havendo abas, a régua do header é a própria borda das abas. */
.page-heading { flex-direction: column; align-items: stretch; gap: 0; padding-bottom: 0; }
.page-heading-main { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--s6); padding-bottom: var(--s5); }
.page-tabs { display: flex; gap: var(--s4); margin-top: calc(var(--s3) * -1); }
.page-tabs[hidden] { display: none; }
.page-tab {
  padding: 0 0 var(--s3);
  border: 0; border-bottom: 2px solid transparent;
  background: none; color: var(--ink-soft);
  font-size: 13px; font-weight: 550; line-height: 20px;
}
.page-tab:hover { color: var(--ink); }
.page-tab.is-active { color: var(--ink); border-bottom-color: var(--brand-600); }
