:root{
  --ux-surface:#ffffff;
  --ux-surface-soft:#f6f9fc;
  --ux-border:#d9e4ef;
  --ux-border-strong:#c7d6e6;
  --ux-text:#17324d;
  --ux-text-soft:#5f748a;
  --ux-blue:#1677ff;
  --ux-blue-soft:#edf5ff;
  --ux-shadow:0 10px 30px rgba(22,42,67,.08);
}

body[data-theme="crm-premium"]{
  color-scheme:light;
}
body[data-theme="crm-premium"] .content,
body[data-theme="crm-premium"] .main,
body[data-theme="crm-premium"] .topbar,
body[data-theme="crm-premium"] .content-page-head{
  color:var(--ux-text);
}
body[data-theme="crm-premium"] .topbar,
body[data-theme="crm-premium"] .content,
body[data-theme="crm-premium"] .system-footer{
  background:#f4f8fc!important;
}
body[data-theme="crm-premium"] .content-page-head,
body[data-theme="crm-premium"] .panel,
body[data-theme="crm-premium"] .alert,
body[data-theme="crm-premium"] .stat-card,
body[data-theme="crm-premium"] .ticket-card,
body[data-theme="crm-premium"] .company-card,
body[data-theme="crm-premium"] .plan-card,
body[data-theme="crm-premium"] .contact-card,
body[data-theme="crm-premium"] .flow-list>*,
body[data-theme="crm-premium"] .history-list>*,
body[data-theme="crm-premium"] .collector-history-list>*,
body[data-theme="crm-premium"] .commercial-grid>*,
body[data-theme="crm-premium"] .integration-request-list>*,
body[data-theme="crm-premium"] .pricing-cards>*,
body[data-theme="crm-premium"] .trend-items>*,
body[data-theme="crm-premium"] .metrics-ranking>*,
body[data-theme="crm-premium"] .ranking>*,
body[data-theme="crm-premium"] .announcement-list>*,
body[data-theme="crm-premium"] .account-selection-grid>*,
body[data-theme="crm-premium"] .finance-account-list>*,
body[data-theme="crm-premium"] .notes-grid>*,
body[data-theme="crm-premium"] .log-file-grid>*,
body[data-theme="crm-premium"] .cron-list>*,
body[data-theme="crm-premium"] .filesystem-list>*,
body[data-theme="crm-premium"] .system-module-grid>*,
body[data-theme="crm-premium"] .extension-grid>*,
body[data-theme="crm-premium"] .endpoint-list>*,
body[data-theme="crm-premium"] .connector-list>*,
body[data-theme="crm-premium"] .embed-app-list>*,
body[data-theme="crm-premium"] .origin-list>*,
body[data-theme="crm-premium"] .admin-catalog-list>*,
body[data-theme="crm-premium"] .integration-catalog-grid>*,
body[data-theme="crm-premium"] .tutorial-grid>*,
body[data-theme="crm-premium"] .directory-grid.groups>*,
body[data-theme="crm-premium"] .cards-list>*{
  background:var(--ux-surface)!important;
  color:var(--ux-text)!important;
  border:1px solid var(--ux-border)!important;
  box-shadow:var(--ux-shadow)!important;
}
body[data-theme="crm-premium"] :is(.panel,.stat-card,.ticket-card,.company-card,.plan-card,.contact-card) :is(p,small,.muted,li,span:not(.badge):not(.btn),label small){
  color:var(--ux-text-soft)!important;
}
body[data-theme="crm-premium"] :is(h1,h2,h3,h4,strong,b,label,th,td,code,legend){
  color:var(--ux-text);
}

/* Menu lateral mais fiel ao layout de referência */
body[data-theme="crm-premium"]:not(.standalone-focus-layout):not(.is-public-page) .sidebar{
  background:linear-gradient(180deg,#0f2036 0%,#13253d 100%)!important;
  border-right:1px solid rgba(255,255,255,.08)!important;
}
body[data-theme="crm-premium"]:not(.standalone-focus-layout):not(.is-public-page) .sidebar nav a{
  min-height:48px!important;
  border-radius:14px!important;
}
body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) .sidebar{
  width:84px!important;
}
body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) .main,
body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) .topbar{margin-left:84px!important}
body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) :is(.brand-copy,.sidebar-menu-search,.menu-label,.logout-label,.embed-session-label){
  display:none!important;
}
body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) .sidebar nav,
body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) .logout{padding-left:10px!important;padding-right:10px!important}
body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) .sidebar nav a,
body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) .logout button{
  justify-content:center!important;
  padding:0!important;
  gap:0!important;
  overflow:visible!important;
}
body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) .sidebar nav a .menu-icon,
body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) .logout .logout-icon{
  margin:0!important;
}

/* Abas e sub-abas */
body[data-theme="crm-premium"] :is(.flow-editor-tabs,.module-tabs,.flux-crud-page-tabs,.flux-crud-modal-tabs,[role="tablist"],.tabs-nav,.settings-tabs,.subtabs){
  display:flex!important;
  flex-wrap:nowrap!important;
  gap:10px!important;
  overflow-x:auto!important;
  padding-bottom:3px!important;
  scrollbar-width:thin;
}
body[data-theme="crm-premium"] :is(.flow-editor-tabs,.module-tabs,.flux-crud-page-tabs,.flux-crud-modal-tabs,[role="tablist"],.tabs-nav,.settings-tabs,.subtabs) > :is(a,button,span,.flux-crud-page-tab,.flux-crud-modal-tab){
  flex:0 0 auto!important;
  min-height:44px!important;
  padding:11px 16px!important;
  border:1px solid var(--ux-border)!important;
  border-radius:14px!important;
  background:var(--ux-surface)!important;
  color:var(--ux-text)!important;
  box-shadow:none!important;
  white-space:nowrap!important;
}
body[data-theme="crm-premium"] :is(.flow-editor-tabs,.module-tabs,.flux-crud-page-tabs,.flux-crud-modal-tabs,[role="tablist"],.tabs-nav,.settings-tabs,.subtabs) > :is(a,button,span,.flux-crud-page-tab,.flux-crud-modal-tab).is-active,
body[data-theme="crm-premium"] :is(.flow-editor-tabs,.module-tabs,.flux-crud-page-tabs,.flux-crud-modal-tabs,[role="tablist"],.tabs-nav,.settings-tabs,.subtabs) > :is(a,button,span,.flux-crud-page-tab,.flux-crud-modal-tab)[aria-selected="true"]{
  background:linear-gradient(135deg,#2979ff,#695bff)!important;
  color:#fff!important;
  border-color:transparent!important;
}
body[data-theme="crm-premium"] .flow-editor-tabs::-webkit-scrollbar,
body[data-theme="crm-premium"] .module-tabs::-webkit-scrollbar,
body[data-theme="crm-premium"] .flux-crud-page-tabs::-webkit-scrollbar,
body[data-theme="crm-premium"] .flux-crud-modal-tabs::-webkit-scrollbar{height:8px}
body[data-theme="crm-premium"] .flow-editor-tabs::-webkit-scrollbar-thumb,
body[data-theme="crm-premium"] .module-tabs::-webkit-scrollbar-thumb,
body[data-theme="crm-premium"] .flux-crud-page-tabs::-webkit-scrollbar-thumb,
body[data-theme="crm-premium"] .flux-crud-modal-tabs::-webkit-scrollbar-thumb{background:#d4dfeb;border-radius:99px}

/* Fluxos: cards do modal e paleta claros */
body[data-theme="crm-premium"] .flow-visual-toolbar,
body[data-theme="crm-premium"] .flow-canvas-viewport,
body[data-theme="crm-premium"] .flow-visual-canvas,
body[data-theme="crm-premium"] .flow-ai-box,
body[data-theme="crm-premium"] .payment-config-box{
  background:var(--ux-surface)!important;
  border:1px solid var(--ux-border)!important;
  color:var(--ux-text)!important;
}
body[data-theme="crm-premium"] .flow-content-choice,
body[data-theme="crm-premium"] .flow-palette-item{
  background:var(--ux-surface)!important;
  color:var(--ux-text)!important;
  border:1px solid var(--ux-border)!important;
  box-shadow:0 6px 16px rgba(20,52,84,.05)!important;
}
body[data-theme="crm-premium"] .flow-content-choice span,
body[data-theme="crm-premium"] .flow-palette-item span{
  background:#edf5ff!important;
  color:#1769c7!important;
}
body[data-theme="crm-premium"] .flow-content-choice.is-active,
body[data-theme="crm-premium"] .flow-palette-item:hover{
  background:var(--ux-blue-soft)!important;
  border-color:#b9d7ff!important;
}
body[data-theme="crm-premium"] .flow-content-choice.is-active span{background:var(--ux-blue)!important;color:#fff!important}

/* Filtros da inbox */
body[data-theme="crm-premium"] .message-view-tools button{
  background:#fff!important;
  color:#17324d!important;
  border:1px solid #cfe0f1!important;
}
body[data-theme="crm-premium"] .message-view-tools button.is-active,
body[data-theme="crm-premium"] .message-view-tools button[aria-pressed="true"]{
  background:#eaf3ff!important;
  color:#145db5!important;
  border-color:#b7d4ff!important;
}

/* Info buttons e modal por cima de tudo */
body[data-theme="crm-premium"] .field-help-ready{position:relative;padding-right:40px!important}
body[data-theme="crm-premium"] .field-help-ready > .field-info-button{
  top:10px!important;
  right:8px!important;
  transform:none!important;
  width:24px!important;
  height:24px!important;
  background:#edf5ff!important;
  color:#1668c8!important;
  border:1px solid #c5daf7!important;
  z-index:4!important;
}
body[data-theme="crm-premium"] .field-help-modal{z-index:4500!important;background:rgba(12,24,38,.46)!important;backdrop-filter:blur(6px)!important}
body[data-theme="crm-premium"] .field-help-dialog{
  background:#fff!important;
  border:1px solid var(--ux-border)!important;
  color:var(--ux-text)!important;
  box-shadow:0 26px 80px rgba(10,27,48,.22)!important;
}
body[data-theme="crm-premium"] .field-help-dialog :is(h3,p,.badge){color:inherit!important}
body[data-theme="crm-premium"] .field-help-dialog p{color:var(--ux-text-soft)!important;line-height:1.75!important}
body[data-theme="crm-premium"] .field-help-close{
  background:#f5f8fc!important;
  color:#17324d!important;
  border:1px solid var(--ux-border)!important;
}
body[data-theme="crm-premium"] :is(.flux-crud-modal,.flux-modal,.flux-system-modal,.crm-drilldown-modal){z-index:3200!important}
body[data-theme="crm-premium"] :is(.flux-crud-modal-dialog,.flux-modal-dialog,.flux-system-modal-dialog,.crm-drilldown-dialog){box-shadow:0 30px 80px rgba(8,28,54,.18)!important}

/* Listagens clicáveis */
body[data-theme="crm-premium"] .flux-clickable-row{
  cursor:pointer;
  transition:transform .16s ease,box-shadow .16s ease,border-color .16s ease,background .16s ease;
}
body[data-theme="crm-premium"] .flux-clickable-row:hover{
  transform:translateY(-1px);
  border-color:#b9d4ef!important;
  box-shadow:0 12px 28px rgba(17,47,80,.11)!important;
  background:#fbfdff!important;
}
body[data-theme="crm-premium"] .flux-clickable-row:focus-visible{
  outline:3px solid rgba(22,119,255,.22)!important;
  outline-offset:2px!important;
}
body[data-theme="crm-premium"] .table-wrap table tbody tr.flux-clickable-row:hover td{background:#f8fbff!important}

/* Gráficos */
body[data-theme="crm-premium"] :is(canvas,[data-metric-chart],.chartjs-render-monitor,.metrics-chart,.chart-card canvas){cursor:pointer}
body[data-theme="crm-premium"] .chart-card,
body[data-theme="crm-premium"] .metrics-card,
body[data-theme="crm-premium"] .realtime-chart-card{
  background:#fff!important;
  border:1px solid var(--ux-border)!important;
  border-radius:18px!important;
  box-shadow:var(--ux-shadow)!important;
}

/* Ajustes menores de alinhamento */
body[data-theme="crm-premium"] .panel-head,
body[data-theme="crm-premium"] .domain-status-head,
body[data-theme="crm-premium"] .flow-section-head{align-items:flex-start!important}
body[data-theme="crm-premium"] .badge{vertical-align:middle}
body[data-theme="crm-premium"] .modal-card,
body[data-theme="crm-premium"] .flux-modal header,
body[data-theme="crm-premium"] .flux-system-modal header{background:#fff!important}

@media (max-width:850px){
  body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) .topbar,
  body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) .main{margin-left:0!important}
}

/* 5.4.5 · acabamento final pedido: superfícies claras, abas sem corte e editor de fluxo fiel ao layout */
body[data-theme="crm-premium"]{
  --ux-card:#ffffff;
  --ux-card-soft:#f8fafc;
  --ux-card-hover:#f5f9ff;
  --ux-navy:#17324d;
}

/* Cards operacionais permanecem claros em todas as telas internas. */
body[data-theme="crm-premium"] .content :is(
  .card,.metric-card,.summary-card,.dashboard-card,.chart-card,.table-card,.provider-card,.request-card,
  .assistant-card,.flow-card,.queue-card,.lead-card,.sales-card,.funnel-card,.integration-card,.endpoint-card,
  .activity-card,.health-card,.settings-card,.account-card,.note-card,.campaign-card,.landing-card,.contact-card,
  .live-summary-card,.live-insight-card,.crm-kpi-card,.metrics-kpi,.stat-card,.plan-card,.company-card,.ticket-card
){
  background:var(--ux-card)!important;
  background-image:none!important;
  color:var(--ux-text)!important;
  border-color:var(--ux-border)!important;
  box-shadow:var(--ux-shadow)!important;
}
body[data-theme="crm-premium"] .content :is(
  .card,.metric-card,.summary-card,.dashboard-card,.chart-card,.table-card,.provider-card,.request-card,
  .assistant-card,.flow-card,.queue-card,.lead-card,.sales-card,.funnel-card,.integration-card,.endpoint-card,
  .activity-card,.health-card,.settings-card,.account-card,.note-card,.campaign-card,.landing-card,.contact-card,
  .live-summary-card,.live-insight-card,.crm-kpi-card,.metrics-kpi,.stat-card,.plan-card,.company-card,.ticket-card
) :is(h1,h2,h3,h4,b,strong,label,legend,td,th){color:var(--ux-text)!important}
body[data-theme="crm-premium"] .content :is(
  .card,.metric-card,.summary-card,.dashboard-card,.chart-card,.table-card,.provider-card,.request-card,
  .assistant-card,.flow-card,.queue-card,.lead-card,.sales-card,.funnel-card,.integration-card,.endpoint-card,
  .activity-card,.health-card,.settings-card,.account-card,.note-card,.campaign-card,.landing-card,.contact-card,
  .live-summary-card,.live-insight-card,.crm-kpi-card,.metrics-kpi,.stat-card,.plan-card,.company-card,.ticket-card
) :is(p,small,.muted){color:var(--ux-text-soft)!important}

/* O menu recolhido mostra somente ícones centralizados, sem pedaços dos nomes. */
@media(min-width:851px){
  body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page){--n4-sidebar:84px!important}
  body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) .sidebar{width:84px!important;min-width:84px!important;max-width:84px!important}
  body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) .main{margin-left:84px!important}
  body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) .topbar{left:84px!important;margin-left:0!important}
  body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) :is(.brand-copy,.sidebar-menu-search,.menu-label,.logout-label,.embed-session-label,.menu-active-dot){display:none!important;width:0!important;max-width:0!important;opacity:0!important;visibility:hidden!important;overflow:hidden!important}
  body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) .nave4-brand-row .brand{justify-content:center!important;padding:0!important;gap:0!important}
  body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) .sidebar nav{padding:12px 13px 22px!important}
  body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) .sidebar nav a,
  body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) .sidebar .logout button{
    width:56px!important;min-width:56px!important;max-width:56px!important;height:48px!important;min-height:48px!important;
    justify-content:center!important;padding:0!important;margin:2px auto!important;gap:0!important;overflow:visible!important
  }
  body[data-theme="crm-premium"].sidebar-collapsed:not(.standalone-focus-layout):not(.is-public-page) .sidebar :is(.menu-icon,.logout-icon){width:24px!important;min-width:24px!important;flex:0 0 24px!important;margin:0!important}
}

/* Abas: uma única linha rolável, textos inteiros e item ativo sempre visível. */
body[data-theme="crm-premium"] :is(
  .crud-tabs,.crud-tabs-multiple,.module-tabs,.growth-tabs,.health-tabs,.flow-editor-tabs,.integration-top-tabs,
  .commercial-top-tabs,.finance-tabs,.contact-tabs,.flux-crud-page-tabs,.flux-crud-modal-tabs,.settings-tabs,
  .tabs-nav,.subtabs,[role="tablist"]
){
  display:flex!important;align-items:center!important;flex-wrap:nowrap!important;gap:8px!important;max-width:100%!important;
  overflow-x:auto!important;overflow-y:hidden!important;padding:6px!important;border:1px solid var(--ux-border)!important;
  border-radius:15px!important;background:#fff!important;scrollbar-width:thin!important;scroll-snap-type:x proximity
}
body[data-theme="crm-premium"] :is(
  .crud-tabs,.crud-tabs-multiple,.module-tabs,.growth-tabs,.health-tabs,.flow-editor-tabs,.integration-top-tabs,
  .commercial-top-tabs,.finance-tabs,.contact-tabs,.flux-crud-page-tabs,.flux-crud-modal-tabs,.settings-tabs,
  .tabs-nav,.subtabs,[role="tablist"]
)>:is(a,button,span,.flux-crud-page-tab,.flux-crud-modal-tab){
  flex:0 0 auto!important;max-width:none!important;min-height:40px!important;padding:9px 14px!important;
  display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:7px!important;
  border:1px solid transparent!important;border-radius:11px!important;background:transparent!important;color:#344b63!important;
  box-shadow:none!important;white-space:nowrap!important;overflow:visible!important;text-overflow:clip!important;scroll-snap-align:start
}
body[data-theme="crm-premium"] :is(
  .crud-tabs,.crud-tabs-multiple,.module-tabs,.growth-tabs,.health-tabs,.flow-editor-tabs,.integration-top-tabs,
  .commercial-top-tabs,.finance-tabs,.contact-tabs,.flux-crud-page-tabs,.flux-crud-modal-tabs,.settings-tabs,
  .tabs-nav,.subtabs,[role="tablist"]
)>:is(a,button,span,.flux-crud-page-tab,.flux-crud-modal-tab):hover{background:#f3f7fb!important;border-color:#dae5f0!important;color:#1767bd!important}
body[data-theme="crm-premium"] :is(
  .crud-tabs,.crud-tabs-multiple,.module-tabs,.growth-tabs,.health-tabs,.flow-editor-tabs,.integration-top-tabs,
  .commercial-top-tabs,.finance-tabs,.contact-tabs,.flux-crud-page-tabs,.flux-crud-modal-tabs,.settings-tabs,
  .tabs-nav,.subtabs,[role="tablist"]
)>:is(.active,.is-active,[aria-selected="true"]){
  background:linear-gradient(135deg,#247cff,#6558f5)!important;color:#fff!important;border-color:transparent!important;
  box-shadow:0 8px 20px rgba(49,104,231,.20)!important
}
body[data-theme="crm-premium"] :is(.crud-tabs,.module-tabs,.health-tabs,.flow-editor-tabs,.flux-crud-page-tabs,.flux-crud-modal-tabs)::-webkit-scrollbar{height:7px}
body[data-theme="crm-premium"] :is(.crud-tabs,.module-tabs,.health-tabs,.flow-editor-tabs,.flux-crud-page-tabs,.flux-crud-modal-tabs)::-webkit-scrollbar-track{background:transparent}
body[data-theme="crm-premium"] :is(.crud-tabs,.module-tabs,.health-tabs,.flow-editor-tabs,.flux-crud-page-tabs,.flux-crud-modal-tabs)::-webkit-scrollbar-thumb{background:#cbd8e6;border-radius:99px}

/* Editor de fluxo: todos os tipos de conteúdo são cards claros e legíveis. */
body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal .flux-modal-dialog,
body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal .flux-modal-dialog>form,
body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal .flow-content-picker,
body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal .flow-content-section,
body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal .flow-button-row,
body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal .payment-config-box,
body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal .flow-ai-box{
  background:#fff!important;background-image:none!important;color:var(--ux-text)!important;border-color:var(--ux-border)!important
}
body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal .flow-content-picker{
  display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:12px!important;padding:2px!important
}
body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal .flow-content-choice{
  min-width:0!important;min-height:72px!important;padding:13px 15px!important;display:flex!important;align-items:center!important;
  justify-content:flex-start!important;gap:12px!important;border:1px solid #d7e3ee!important;border-radius:15px!important;
  background:#fff!important;background-image:none!important;color:#253e57!important;font-size:14px!important;font-weight:750!important;
  box-shadow:0 5px 15px rgba(20,50,80,.045)!important
}
body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal .flow-content-choice>span{
  width:42px!important;height:42px!important;min-width:42px!important;display:grid!important;place-items:center!important;
  border-radius:12px!important;background:#edf5ff!important;color:#176fc8!important;font-size:18px!important
}
body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal .flow-content-choice:hover{
  background:#f6faff!important;border-color:#b9d5f3!important;color:#145fae!important;transform:translateY(-1px)
}
body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal .flow-content-choice.is-active{
  background:#eaf3ff!important;background-image:none!important;border-color:#4b91ff!important;color:#145fae!important;
  box-shadow:0 0 0 2px rgba(39,126,255,.10)!important
}
body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal .flow-content-choice.is-active>span{background:#277eff!important;color:#fff!important}
body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal :is(label,legend,h2,h3,b,strong){color:var(--ux-text)!important}
body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal :is(p,small,.muted){color:var(--ux-text-soft)!important}
body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal .flux-modal-dialog>header{
  background:#f8fafc!important;border-bottom:1px solid var(--ux-border)!important;color:var(--ux-text)!important
}
body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal .flux-modal-dialog>header>button{
  background:#fff!important;color:#435a72!important;border:1px solid #d6e1ec!important;box-shadow:0 4px 12px rgba(20,48,78,.08)!important
}
body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal .flux-modal-dialog>header>button:hover{background:#edf5ff!important;color:#176fc8!important;border-color:#bcd6f4!important}

/* Modal de informação: sempre acima de qualquer outro modal, claro e bem explicado. */
body[data-theme="crm-premium"] .field-help-ready{position:relative!important;padding-right:42px!important}
body[data-theme="crm-premium"] .field-help-ready>.field-info-button{
  position:absolute!important;top:0!important;right:4px!important;bottom:auto!important;left:auto!important;transform:none!important;
  width:28px!important;height:28px!important;min-width:28px!important;padding:0!important;display:grid!important;place-items:center!important;
  border:1px solid #bdd5f0!important;border-radius:50%!important;background:#edf5ff!important;color:#176fc8!important;
  font-size:13px!important;font-weight:900!important;line-height:1!important;box-shadow:none!important;z-index:8!important
}
body[data-theme="crm-premium"] .field-help-ready>.field-info-button:hover{background:#277eff!important;color:#fff!important;border-color:#277eff!important}
body[data-theme="crm-premium"] .field-help-modal{z-index:95000!important;background:rgba(15,35,58,.46)!important;backdrop-filter:blur(8px)!important}
body[data-theme="crm-premium"] .field-help-dialog{
  width:min(620px,calc(100vw - 32px))!important;padding:28px!important;border:1px solid #d6e2ee!important;border-radius:22px!important;
  background:#fff!important;background-image:none!important;color:var(--ux-text)!important;box-shadow:0 30px 100px rgba(7,29,55,.25)!important
}
body[data-theme="crm-premium"] .field-help-dialog .badge{display:inline-flex!important;background:#eaf3ff!important;color:#176fc8!important;border-color:#c4dcf7!important}
body[data-theme="crm-premium"] .field-help-dialog h3{margin:14px 46px 8px 0!important;color:var(--ux-text)!important;font-size:23px!important}
body[data-theme="crm-premium"] .field-help-dialog p{margin:0!important;color:var(--ux-text-soft)!important;line-height:1.7!important}
body[data-theme="crm-premium"] .field-help-dialog ul{margin:16px 0 0!important;padding:0!important;display:grid!important;gap:9px!important;list-style:none!important}
body[data-theme="crm-premium"] .field-help-dialog li{position:relative!important;padding:11px 13px 11px 36px!important;border:1px solid #e0e8f1!important;border-radius:12px!important;background:#f8fafc!important;color:#425a72!important;line-height:1.55!important}
body[data-theme="crm-premium"] .field-help-dialog li::before{content:"✓";position:absolute;left:13px;top:10px;color:#1677d2;font-weight:900}
body[data-theme="crm-premium"] .field-help-close{top:16px!important;right:16px!important;background:#f6f9fc!important;color:#405970!important;border:1px solid #d7e2ec!important}
body[data-theme="crm-premium"] .field-help-close:hover{background:#eaf3ff!important;color:#176fc8!important;border-color:#bdd5f0!important}
body[data-theme="crm-premium"] :is(.flux-crud-modal,.flux-modal,.flux-system-modal,.crm-drilldown-modal,.modal-backdrop){z-index:70000!important}
body[data-theme="crm-premium"] .flux-system-modal{z-index:76000!important}
body[data-theme="crm-premium"] .crm-drilldown-modal{z-index:74000!important}
body[data-theme="crm-premium"] .field-help-modal{z-index:95000!important}

/* Listagens e gráficos deixam claro que podem ser abertos. */
body[data-theme="crm-premium"] .flux-clickable-row{position:relative!important;cursor:pointer!important}
body[data-theme="crm-premium"] .flux-clickable-row::after{
  content:"↗";position:absolute;right:10px;top:10px;width:24px;height:24px;display:grid;place-items:center;
  border:1px solid #d6e3ef;border-radius:8px;background:#f6f9fc;color:#6b8197;font-size:12px;opacity:0;transform:translateY(2px);
  transition:opacity .16s,transform .16s,background .16s,color .16s
}
body[data-theme="crm-premium"] tr.flux-clickable-row::after{content:none!important}
body[data-theme="crm-premium"] .flux-clickable-row:hover::after,
body[data-theme="crm-premium"] .flux-clickable-row:focus-visible::after{opacity:1;transform:none;background:#eaf3ff;color:#176fc8}
body[data-theme="crm-premium"] .flux-chart-clickable,
body[data-theme="crm-premium"] [data-crm-chart].has-drilldown,
body[data-theme="crm-premium"] [data-dashboard-operation-point]{cursor:pointer!important}
body[data-theme="crm-premium"] .crm-chart-clickable:focus-visible,
body[data-theme="crm-premium"] [data-dashboard-operation-point]:focus-visible{outline:3px solid rgba(22,119,255,.23)!important;outline-offset:3px!important}
body[data-theme="crm-premium"] .crm-chart-drill-hint,
body[data-theme="crm-premium"] .live-chart-click-hint{color:#536c85!important;background:#f4f8fc!important;border:1px solid #dbe6f1!important;border-radius:10px!important;padding:8px 10px!important}

/* Cabeçalhos, ações e ícones de informação não se sobrepõem. */
body[data-theme="crm-premium"] :is(.panel-head,.flow-section-head,.domain-status-head,.custom-page-head){display:flex!important;align-items:flex-start!important;gap:14px!important}
body[data-theme="crm-premium"] :is(.panel-head,.flow-section-head,.domain-status-head,.custom-page-head)>:first-child{min-width:0!important;flex:1 1 auto!important}
body[data-theme="crm-premium"] :is(.panel-head,.flow-section-head,.domain-status-head,.custom-page-head)>.actions{flex:0 0 auto!important;max-width:100%!important}

@media(max-width:980px){
  body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal .flow-content-picker{grid-template-columns:repeat(2,minmax(0,1fr))!important}
}
@media(max-width:560px){
  body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal .flow-content-picker{grid-template-columns:1fr!important}
  body.route-flows-edit[data-theme="crm-premium"] .flow-editor-modal .flow-content-choice{min-height:58px!important}
  body[data-theme="crm-premium"] .field-help-ready{padding-right:38px!important}
  body[data-theme="crm-premium"] .field-help-dialog{padding:22px!important}
}
