/* SIMIA Saúde: folha de estilo única. Sem fonte nem arquivo de fora.
   Letra grande, alto contraste, um assunto por tela. Só recursos antigos de CSS
   (flexbox e cores fixas), para abrir em navegador de qualquer máquina. */

* { box-sizing: border-box; }
html { font-size: 17px; }
body {
  margin: 0;
  font-family: "Segoe UI", Arial, Helvetica, sans-serif;
  line-height: 1.5;
  color: #1d2733;
  background: #f2f5f8;
}
a { color: #0b5cab; }
a:hover { text-decoration: underline; }
h1 { font-size: 1.6rem; line-height: 1.25; margin: 0; }
h2 { font-size: 1.2rem; margin: 0 0 12px; }
p { margin: 0 0 12px; }
small { font-size: 0.82rem; color: #51606f; }
:focus { outline: 3px solid #f0a000; outline-offset: 2px; }
.so-leitor { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }

/* Faixa do ambiente: aparece em tudo que não é produção. */
.faixa-ambiente {
  background: #b45309; color: #fff; text-align: center; font-weight: bold;
  letter-spacing: 0.06em; padding: 5px 12px; font-size: 0.9rem;
}
.ambiente-desenvolvimento .faixa-ambiente { background: #6d28d9; }
.ambiente-homologacao .faixa-ambiente { background: #b45309; }

/* Topo: produto e quem está logado. */
.topo {
  display: flex; flex-wrap: wrap; align-items: center;
  background: #0f3d6b; color: #fff; padding: 10px 20px;
}
.marca { color: #fff; font-size: 1.25rem; font-weight: bold; text-decoration: none; margin-right: 28px; }
.quem { flex: 1 1 auto; min-width: 240px; font-size: 0.95rem; }
.quem-nome { font-weight: bold; margin-right: 10px; }
.quem-perfil, .quem-vinculo {
  display: inline-block; background: #1f5a94; border-radius: 4px; padding: 1px 9px; margin: 2px 6px 2px 0;
}
.quem-vinculo { background: #17657a; }
.topo-acoes { display: flex; align-items: center; }
.topo-acoes .botao { margin-left: 8px; }
.em-linha { display: inline; margin: 0; }

/* Corpo: menu à esquerda e conteúdo. */
.corpo { display: flex; align-items: stretch; min-height: calc(100vh - 120px); }
.menu { flex: 0 0 250px; background: #fff; border-right: 1px solid #c9d3de; padding: 12px 0 30px; }
.menu-grupo {
  font-size: 0.78rem; font-weight: bold; text-transform: uppercase; letter-spacing: 0.06em;
  color: #51606f; padding: 16px 20px 4px;
}
.menu-item { display: block; padding: 8px 20px; color: #1d2733; text-decoration: none; border-left: 4px solid transparent; }
.menu-item:hover { background: #eaf1f8; text-decoration: none; }
.menu-item.atual { background: #e2edf8; border-left-color: #0b5cab; font-weight: bold; }
.conteudo { flex: 1 1 auto; min-width: 0; padding: 22px 26px 50px; max-width: 1300px; }
.rodape { text-align: center; font-size: 0.82rem; color: #51606f; padding: 14px; border-top: 1px solid #c9d3de; background: #fff; }

/* Cabeçalho de cada tela. */
.cabecalho-tela { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; margin-bottom: 16px; }
.cabecalho-tela .botoes { margin-top: 8px; }
.cabecalho-tela .botoes .botao { margin: 0 0 6px 8px; }
.subtitulo { color: #51606f; margin: 0 0 2px; }
.voltar { display: inline-block; margin-bottom: 6px; font-size: 0.92rem; }

/* Cartões. */
.cartao { background: #fff; border: 1px solid #c9d3de; border-radius: 6px; padding: 18px 20px; margin-bottom: 18px; }

/* Botões. */
.botao {
  display: inline-block; font: inherit; font-weight: 600; line-height: 1.3; cursor: pointer;
  padding: 9px 16px; border-radius: 5px; border: 1px solid #8a99a8; background: #fff; color: #1d2733;
  text-decoration: none; vertical-align: middle;
}
.botao:hover { background: #eaf1f8; text-decoration: none; }
.botao.principal { background: #0b5cab; border-color: #0b5cab; color: #fff; }
.botao.principal:hover { background: #094a8a; }
.botao.perigo { border-color: #b3261e; color: #b3261e; }
.botao.perigo:hover { background: #fbe9e7; }
.botao.discreto { border-color: transparent; background: transparent; color: #0b5cab; }
.topo .botao.discreto { color: #fff; border-color: #5d88b3; }
.topo .botao.discreto:hover { background: #1f5a94; }
.botao.largo { width: 100%; }
.botao.travado { background: #eef1f4; color: #51606f; border-style: dashed; }

/* Cadeado desenhado em CSS: ação que o perfil não pode. */
.cadeado {
  display: inline-block; position: relative; width: 12px; height: 9px; margin: 6px 7px 0 0;
  background: #51606f; border-radius: 2px; vertical-align: baseline;
}
.cadeado:before {
  content: ""; position: absolute; left: 2px; top: -7px; width: 8px; height: 8px;
  border: 2px solid #51606f; border-bottom: 0; border-radius: 5px 5px 0 0; box-sizing: border-box;
}
.cadeado.grande { width: 44px; height: 34px; margin: 26px 0 10px; border-radius: 5px; background: #b3261e; }
.cadeado.grande:before { left: 8px; top: -24px; width: 28px; height: 26px; border-width: 6px; border-color: #b3261e; border-radius: 16px 16px 0 0; }

/* Mensagens. */
.aviso { border: 1px solid #8a99a8; border-left-width: 6px; border-radius: 4px; background: #fff; padding: 10px 14px; margin-bottom: 12px; }
.aviso.success { border-color: #1a7f37; background: #e9f7ec; }
.aviso.error { border-color: #b3261e; background: #fdecea; }
.aviso.warning { border-color: #b45309; background: #fff5e0; }
.aviso.info { border-color: #0b5cab; background: #e8f1fb; }

/* Formulários. */
.formulario { max-width: 720px; }
.campo { margin-bottom: 16px; }
.campo label { display: block; font-weight: 600; margin-bottom: 4px; }
.campo input[type=text], .campo input[type=search], .campo input[type=password], .campo input[type=email],
.campo input[type=number], .campo input[type=date], .campo input[type=tel], .campo input[type=url],
.campo input[type=file], .campo select, .campo textarea {
  display: block; width: 100%; font: inherit; color: #1d2733; background: #fff;
  padding: 9px 10px; border: 1px solid #8a99a8; border-radius: 4px;
}
.campo input[disabled], .campo select[disabled], .campo textarea[disabled] { background: #eef1f4; color: #51606f; }
.campo .caixa { font-weight: normal; display: block; }
.campo .caixa input { width: 20px; height: 20px; vertical-align: middle; margin: 0 8px 0 0; }
.campo .caixa span { vertical-align: middle; font-weight: 600; }
/* Várias caixas no mesmo campo (exemplo: especialidades do profissional). */
.campo div label { font-weight: normal; padding: 3px 0; }
.campo div label input[type=checkbox] { width: 20px; height: 20px; vertical-align: middle; margin: 0 8px 0 0; }
.campo.com-erro input, .campo.com-erro select, .campo.com-erro textarea { border-color: #b3261e; border-width: 2px; }
.erro-campo { color: #b3261e; font-weight: 600; margin-top: 5px; }
.erro-campo ul, .erro-campo li { margin: 0; padding: 0; list-style: none; }
.ajuda { color: #51606f; font-size: 0.9rem; margin-top: 4px; }
.asterisco { color: #b3261e; }
.acoes-formulario { margin: 20px 0 8px; }
.acoes-formulario .botao { margin-right: 8px; }
.oculto { display: none; }

/* Filtros da lista. */
.filtros { display: flex; flex-wrap: wrap; align-items: flex-end; padding-bottom: 6px; }
.filtros .campo { flex: 1 1 190px; margin: 0 14px 12px 0; max-width: 320px; }
.filtros .acoes-filtro { flex: 0 0 auto; }
.contagem { color: #51606f; margin-bottom: 8px; }

/* Tabelas. */
.tabela-rolagem { overflow-x: auto; background: #fff; border: 1px solid #c9d3de; border-radius: 6px; margin-bottom: 14px; }
.cartao .tabela-rolagem { border: 0; margin-bottom: 8px; }
.tabela { width: 100%; border-collapse: collapse; }
.tabela th, .tabela td { text-align: left; vertical-align: top; padding: 9px 12px; border-bottom: 1px solid #dde4ec; }
.tabela thead th { background: #e9eef4; font-size: 0.9rem; white-space: nowrap; }
.tabela thead th a { color: #1d2733; }
.tabela tbody tr:hover { background: #f6f9fc; }
.tabela.compacta th, .tabela.compacta td { padding: 6px 10px; }
.tabela .numero { text-align: right; font-weight: bold; }
.col-caixa { width: 38px; }
.col-caixa input { width: 20px; height: 20px; }
.lotes { margin-bottom: 14px; }
.lotes .botao { margin-left: 8px; }
.paginacao { margin: 8px 0 18px; }
.paginacao span { margin: 0 12px; color: #51606f; }
.vazio { color: #51606f; }

/* Ficha. */
.ficha { margin: 0; }
.ficha-linha { display: flex; flex-wrap: wrap; padding: 8px 0; border-bottom: 1px solid #e6ebf1; }
.ficha-linha:last-child { border-bottom: 0; }
.ficha dt { flex: 0 0 260px; font-weight: 600; color: #51606f; }
.ficha dd { flex: 1 1 300px; margin: 0; }
.abas { display: flex; flex-wrap: wrap; border-bottom: 2px solid #c9d3de; margin-bottom: 16px; }
.aba { padding: 9px 18px; color: #1d2733; text-decoration: none; border: 1px solid transparent; border-bottom: 0; border-radius: 6px 6px 0 0; margin-bottom: -2px; }
.aba:hover { background: #eaf1f8; text-decoration: none; }
.aba.atual { background: #fff; border-color: #c9d3de; border-bottom: 2px solid #fff; font-weight: bold; }
.lista-simples { margin: 0 0 14px 20px; padding: 0; }

/* Abas com filhos (exemplo: unidades, contratos e profissionais do prestador). */
h3 { font-size: 1.08rem; margin: 0 0 8px; }
h3 small { font-weight: normal; margin-left: 8px; }
h4 { font-size: 1rem; margin: 0 0 6px; }
.cabecalho-aba { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.cabecalho-aba .botoes .botao { margin: 0 0 6px 8px; }
.bloco-filho { border-top: 2px solid #c9d3de; padding-top: 14px; margin-top: 18px; }
.acoes-linha .botao { padding: 3px 10px; font-size: 0.88rem; margin: 0 4px 4px 0; }
.duas-colunas { display: flex; flex-wrap: wrap; margin: 10px -10px 0; }
.duas-colunas .coluna { flex: 1 1 320px; margin: 0 10px 10px; }
.etiqueta { display: inline-block; font-size: 0.8rem; font-weight: 600; border-radius: 4px; padding: 0 8px; background: #e9eef4; color: #1d2733; }
.etiqueta.vigente { background: #e9f7ec; color: #14632b; }
.etiqueta.inativo { background: #fdecea; color: #8a2c22; }
.tabela .valor { text-align: right; white-space: nowrap; }
.campo-na-tabela input { font: inherit; width: 100%; min-width: 110px; padding: 6px 8px; border: 1px solid #8a99a8; border-radius: 4px; }
.campo-na-tabela.com-erro input { border-color: #b3261e; border-width: 2px; }

/* Histórico e auditoria. */
.historico td { font-size: 0.94rem; }
.historico tr.inicio-grupo td { border-top: 2px solid #c9d3de; }
.antes { color: #8a2c22; text-decoration: line-through; }
.depois { color: #14632b; font-weight: 600; }

/* Grade de permissões. */
.grade .col-bit { text-align: center; width: 130px; }
.grade tr.grupo th { background: #f2f5f8; font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.05em; color: #51606f; }
.grade input[type=checkbox] { width: 22px; height: 22px; vertical-align: middle; }
.grade .nao-se-aplica { background: #f4f5f7; color: #6b7785; }
.grade .nao-se-aplica small { display: block; }
.visao-perfis .letras { font-weight: bold; letter-spacing: 0.15em; text-align: center; }
.visao-perfis thead th { text-align: center; white-space: normal; }
.visao-perfis thead th:first-child { text-align: left; }

/* Páginas de aviso (acesso negado, registro de outro município, sessão que mudou). */
.pagina-aviso { max-width: 640px; margin: 24px auto; background: #fff; border: 1px solid #c9d3de; border-radius: 6px; padding: 24px 28px; }
.pagina-aviso.negado { border-top: 6px solid #b3261e; }
.pagina-aviso .destaque { font-size: 1.15rem; font-weight: 600; }

/* Tela de entrada. */
.entrada { max-width: 430px; margin: 34px auto; }
.entrada h1 { margin-bottom: 6px; }

/* Início: atalhos. */
.atalhos { display: flex; flex-wrap: wrap; margin: 0 -8px; }
.atalho {
  flex: 1 1 230px; max-width: 320px; margin: 0 8px 16px; padding: 16px 18px; background: #fff;
  border: 1px solid #c9d3de; border-left: 6px solid #0b5cab; border-radius: 6px; color: #1d2733; text-decoration: none;
}
.atalho:hover { background: #eaf1f8; text-decoration: none; }
.atalho-grupo { display: block; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.05em; color: #51606f; }
.atalho-nome { display: block; font-size: 1.1rem; font-weight: bold; }

/* Situação do ambiente: 3 blocos. */
.blocos { display: flex; flex-wrap: wrap; margin: 0 -8px; }
.bloco { flex: 1 1 280px; margin: 0 8px 16px; }
.total-bloco { font-size: 2.4rem; font-weight: bold; line-height: 1.1; margin: 0 0 4px; color: #0f3d6b; }

/* Telas estreitas: o menu vai para cima. */
@media (max-width: 860px) {
  .corpo { display: block; }
  .menu { border-right: 0; border-bottom: 1px solid #c9d3de; padding-bottom: 10px; }
  .conteudo { padding: 16px 14px 40px; }
  .ficha dt { flex-basis: 100%; }
}

@media print {
  .topo-acoes, .menu, .botoes, .filtros, .lotes, .paginacao, .faixa-ambiente { display: none; }
  body { background: #fff; }
}
