/* ===== Ever Growth brand override ===== */

/* Logo size cap */
img[src*="logo"], img.css-1uyvpz5 {
  max-height: 40px !important;
  max-width: 180px !important;
  width: auto !important;
  height: auto !important;
  object-fit: contain !important;
}

/* AppBar/Toolbar fixa (quando houver) → azul Ever + texto branco */
.MuiAppBar-root, .MuiAppBar-colorPrimary, .MuiPaper-root.MuiAppBar-root {
  background-color: #0066F1 !important;
  color: #FFFFFF !important;
  background-image: none !important;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1) !important;
}
.MuiAppBar-root .MuiTypography-root,
.MuiAppBar-root a,
.MuiAppBar-root .MuiSvgIcon-root,
.MuiAppBar-root .MuiToolbar-root > *:not(.MuiButton-contained):not(.MuiButton-outlined) {
  color: #FFFFFF !important;
}
.MuiAppBar-root .MuiSvgIcon-root, .MuiAppBar-root svg {
  fill: currentColor !important;
}

/* Sidebar Drawer → azul Ever */
.MuiDrawer-paper {
  background-color: #0066F1 !important;
  color: #FFFFFF !important;
  background-image: none !important;
}
.MuiDrawer-paper .MuiListItemIcon-root,
.MuiDrawer-paper .MuiListItemText-primary,
.MuiDrawer-paper .MuiSvgIcon-root,
.MuiDrawer-paper .MuiTypography-root,
.MuiDrawer-paper .MuiButtonBase-root {
  color: #FFFFFF !important;
}
.MuiDrawer-paper .MuiSvgIcon-root, .MuiDrawer-paper svg {
  fill: currentColor !important;
}
.MuiDrawer-paper .MuiListItemButton-root:hover,
.MuiDrawer-paper .MuiIconButton-root:hover {
  background-color: rgba(255,255,255,0.15) !important;
}
.MuiDrawer-paper .Mui-selected,
.MuiDrawer-paper .MuiListItemButton-root.Mui-selected {
  background-color: rgba(255,255,255,0.22) !important;
}

/* ===== BOTÕES — fix anti-invisibilidade (global) ===== */

/* Button CONTAINED primary → sempre bem destacado */
.MuiButton-contained.MuiButton-colorPrimary,
.MuiAppBar-root .MuiButton-contained {
  background-color: #0066F1 !important;
  color: #FFFFFF !important;
  box-shadow: 0 2px 6px rgba(0,102,241,0.3) !important;
}
.MuiButton-contained.MuiButton-colorPrimary:hover {
  background-color: #0B1E5E !important;
}
.MuiButton-contained.MuiButton-colorPrimary .MuiSvgIcon-root,
.MuiButton-contained.MuiButton-colorPrimary svg {
  color: #FFFFFF !important;
  fill: #FFFFFF !important;
}
/* Dentro da AppBar azul → inverte: branco com texto azul */
.MuiAppBar-root .MuiButton-contained.MuiButton-colorPrimary {
  background-color: #FFFFFF !important;
  color: #0066F1 !important;
}
.MuiAppBar-root .MuiButton-contained.MuiButton-colorPrimary svg {
  color: #0066F1 !important;
  fill: #0066F1 !important;
}

/* Button OUTLINED primary (Copiloto IA, Importar, etc) — SEMPRE borda visível */
.MuiButton-outlined.MuiButton-colorPrimary {
  background-color: #FFFFFF !important;
  color: #0066F1 !important;
  border: 1.5px solid #0066F1 !important;
}
.MuiButton-outlined.MuiButton-colorPrimary:hover {
  background-color: #F0F6FF !important;
  border-color: #0B1E5E !important;
  color: #0B1E5E !important;
}
.MuiButton-outlined.MuiButton-colorPrimary .MuiSvgIcon-root,
.MuiButton-outlined.MuiButton-colorPrimary svg,
.MuiButton-outlined.MuiButton-colorPrimary span {
  color: #0066F1 !important;
  fill: #0066F1 !important;
}

/* IconButton primary (histórico, undo, redo no editor) */
.MuiIconButton-root.MuiIconButton-colorPrimary {
  background-color: #FFFFFF !important;
  color: #0066F1 !important;
  border: 1px solid rgba(0,102,241,0.4) !important;
}
.MuiIconButton-root.MuiIconButton-colorPrimary svg,
.MuiIconButton-root.MuiIconButton-colorPrimary .MuiSvgIcon-root {
  color: #0066F1 !important;
  fill: #0066F1 !important;
}
.MuiIconButton-root.MuiIconButton-colorPrimary:hover {
  background-color: #F0F6FF !important;
}

/* Dentro de AppBar azul, IconButton deve ser transparente com icon branco */
.MuiAppBar-root .MuiIconButton-root,
.MuiDrawer-paper .MuiIconButton-root {
  background-color: transparent !important;
  color: #FFFFFF !important;
  border: none !important;
}
.MuiAppBar-root .MuiIconButton-root svg,
.MuiDrawer-paper .MuiIconButton-root svg {
  color: #FFFFFF !important;
  fill: #FFFFFF !important;
}

/* Logo chip pro login/public pages */
body > #root img[src="/logo.svg"]:not(.MuiAppBar-root img):not(.MuiDrawer-paper img) {
  padding: 4px 10px;
  background: #FFFFFF;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  max-height: 56px !important;
  max-width: 200px !important;
}
