/* SGW V168 - elimina FOUC / dupla tela do menu e da página Clientes */

/* O menu legado existe no HTML por compatibilidade, mas não pode aparecer antes
   do menu oficial V53/V166 ser construído pelo JS. */
body.sgw-sidebar-v39-on .app-shell > aside.sidebar,
body.sgw53-sidebar-fixed .app-shell > aside.sidebar,
body.sgw-sidebar-v39-on .app-shell > .sidebar,
body.sgw53-sidebar-fixed .app-shell > .sidebar {
  display:none!important;
}

/* A largura útil já nasce correta no primeiro paint. */
body.sgw-sidebar-v39-on .app-shell,
body.sgw53-sidebar-fixed .app-shell {
  width:100%!important;
  max-width:none!important;
  min-width:0!important;
}

body.sgw-sidebar-v39-on .content-area,
body.sgw53-sidebar-fixed .content-area {
  margin-left:0!important;
  width:100%!important;
  max-width:none!important;
  min-width:0!important;
}

/* A página Clientes recebe a classe premium no HTML antes de o navegador pintar.
   Assim não existe mais a versão compacta por alguns milissegundos. */
body.sgw-clientes-premium .kpi-row,
body.sgw-clientes-premium .clientes-toolbar,
body.sgw-clientes-premium .action-toolbar,
body.sgw-clientes-premium .clientes-page {
  visibility:visible!important;
}

/* Evita animações/transições no primeiro quadro que davam sensação de segunda tela. */
html:not([data-sgw-v168-sidebar="ready"]) body.sgw-sidebar-v39-on *,
html:not([data-sgw-v168-sidebar="ready"]) body.sgw53-sidebar-fixed * {
  transition:none!important;
  animation:none!important;
}
