/* SERDAL DEV — cor institucional #026666 */
:root {
  --cor: #026666; --cor-escura: #014848; --cor-clara: #e3f1f1; --cor-borda: #b9dada;
  --fundo: #f3f6f6; --cartao: #fff; --texto: #1d2b2b; --suave: #5b6b6b; --linha: #dde5e5;
  --erro: #b42318; --erro-fundo: #fdecea; --ok: #1a7f4b; --ok-fundo: #e6f4ec;
  --alerta: #a15c00; --alerta-fundo: #fff4e0; --info-fundo: #e8f1fb; --info: #1f4e8c;
  --raio: 10px; --sombra: 0 1px 2px rgba(0,0,0,.06), 0 1px 8px rgba(2,102,102,.06);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--fundo); color: var(--texto);
  font: 15px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif; }
a { color: var(--cor); }
h1 { font-size: 1.5rem; margin: 0 0 .25rem; line-height: 1.25; }
h2 { font-size: 1.1rem; margin: 1.5rem 0 .5rem; }
.cartao h2 { margin-top: 0; }
h3 { font-size: .95rem; margin: 1.25rem 0 .4rem; color: var(--suave); }
.sub { color: var(--suave); margin: 0 0 1rem; }
.nota { color: var(--suave); font-size: .9rem; }
.opcional { color: var(--suave); font-weight: 400; font-size: .85rem; }
.escondido { display: none !important; }
code { background: var(--cor-clara); padding: .1rem .35rem; border-radius: 5px; }

/* topo */
.topo { background: var(--cor); color: #fff; position: sticky; top: 0; z-index: 10; }
.topo-in { max-width: 1180px; margin: 0 auto; padding: 0 16px; display: flex; align-items: center; min-height: 56px; gap: 1rem; }
.marca { color: #fff; text-decoration: none; font-weight: 600; letter-spacing: .04em; display: flex; align-items: center; gap: .5rem; white-space: nowrap; }
.marca b { font-weight: 800; }
.marca-s { background: #fff; color: var(--cor); width: 28px; height: 28px; border-radius: 7px; display: inline-grid; place-items: center; font-weight: 800; }
.menu { display: flex; align-items: center; gap: .25rem; flex: 1; }
.menu a, .menu .link { color: #fff; text-decoration: none; padding: .45rem .7rem; border-radius: 8px; opacity: .9; font: inherit; }
.menu a:hover, .menu .link:hover { background: rgba(255,255,255,.12); opacity: 1; }
.menu a.ativo { background: rgba(255,255,255,.18); opacity: 1; font-weight: 600; }
.menu-sep { flex: 1; }
.menu-usuario { font-size: .9rem; }
.form-sair { margin: 0; }
.link { background: none; border: 0; cursor: pointer; }
.menu-botao { display: none; margin-left: auto; background: none; border: 1px solid rgba(255,255,255,.4); color: #fff; font-size: 1.2rem; border-radius: 8px; padding: .2rem .6rem; cursor: pointer; }

main.conteudo { max-width: 1180px; margin: 0 auto; padding: 20px 16px 48px; }
.estreito { max-width: 680px; margin: 0 auto; }
.centro { text-align: center; padding-top: 2rem; }
.erro-codigo { font-size: 3rem; font-weight: 800; color: var(--cor); margin: 0; }

/* cabeçalho de página */
.cabeca { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; margin-bottom: 1rem; flex-wrap: wrap; }
.cabeca-acoes { display: flex; gap: .5rem; flex-wrap: wrap; }
.migalha { margin: 0 0 .75rem; font-size: .9rem; }
.migalha a { text-decoration: none; }
.numero { color: var(--suave); margin: 0 0 .25rem; font-size: .9rem; }
.selos { margin: .5rem 0 0; display: flex; flex-wrap: wrap; gap: .35rem; align-items: center; }

/* botões */
.botao { display: inline-flex; align-items: center; justify-content: center; gap: .35rem; padding: .55rem 1rem; border-radius: 8px;
  border: 1px solid var(--cor-borda); background: #fff; color: var(--cor); font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; min-height: 40px; }
.botao:hover { background: var(--cor-clara); }
.botao-cheio { background: var(--cor); border-color: var(--cor); color: #fff; }
.botao-cheio:hover { background: var(--cor-escura); }
.botao-perigo { color: var(--erro); border-color: #f0c2bd; }
.botao-perigo:hover { background: var(--erro-fundo); }
.botao-icone { padding: .3rem .55rem; min-height: 34px; min-width: 34px; }
.botao[disabled] { opacity: .35; cursor: default; }
.botao:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible { outline: 3px solid #7cc4c4; outline-offset: 1px; }

/* avisos */
.avisos { margin-bottom: 1rem; }
.aviso { padding: .7rem 1rem; border-radius: 8px; margin: 0 0 .5rem; }
.aviso-erro { background: var(--erro-fundo); color: var(--erro); }
.aviso-ok { background: var(--ok-fundo); color: var(--ok); }
.aviso-info { background: var(--info-fundo); color: var(--info); }

/* cartões e indicadores */
.cartao { background: var(--cartao); border-radius: var(--raio); box-shadow: var(--sombra); padding: 1.1rem 1.25rem; margin-bottom: 1rem; }
.destaque { border: 2px solid var(--cor); }
.resumo { display: grid; grid-template-columns: repeat(4, 1fr); gap: .75rem; margin-bottom: 1rem; }
.resumo-6 { grid-template-columns: repeat(6, 1fr); }
.indicador { background: #fff; border-radius: var(--raio); box-shadow: var(--sombra); padding: .85rem 1rem; text-decoration: none; color: var(--texto); border-left: 4px solid var(--cor-borda); }
.indicador b { display: block; font-size: 1.6rem; line-height: 1.1; color: var(--cor); }
.indicador span { color: var(--suave); font-size: .85rem; }
.indicador-alerta { border-left-color: #e08a00; }
.indicador-alerta b { color: var(--alerta); }

/* abas */
.abas { display: flex; gap: .25rem; border-bottom: 1px solid var(--linha); margin: 1rem 0 .75rem; overflow-x: auto; }
.abas a { padding: .5rem .9rem; text-decoration: none; color: var(--suave); border-bottom: 3px solid transparent; white-space: nowrap; }
.abas a.ativa { color: var(--cor); border-bottom-color: var(--cor); font-weight: 600; }

/* lista de chamados */
.lista { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.linha { display: flex; align-items: center; gap: .9rem; background: #fff; border-radius: var(--raio); box-shadow: var(--sombra);
  padding: .75rem 1rem; text-decoration: none; color: var(--texto); border-left: 4px solid transparent; }
a.linha:hover { border-left-color: var(--cor); }
.linha-atencao { border-left-color: #e08a00; background: #fffaf0; }
.linha-num { color: var(--suave); font-variant-numeric: tabular-nums; font-size: .9rem; min-width: 3.2rem; }
.linha-titulo { flex: 1; min-width: 0; display: flex; flex-direction: column; text-decoration: none; color: var(--texto); }
.linha-titulo strong { overflow-wrap: anywhere; }
.linha-titulo small { color: var(--suave); }
.linha-selos { display: flex; flex-wrap: wrap; gap: .3rem; justify-content: flex-end; }
.linha-com-acao form { margin: 0; }
.inativo { opacity: .6; }
.vazio { color: var(--suave); background: #fff; border: 1px dashed var(--cor-borda); border-radius: var(--raio); padding: 1.25rem; text-align: center; }

/* selos */
.selo { display: inline-block; font-size: .78rem; font-weight: 600; padding: .15rem .55rem; border-radius: 999px; white-space: nowrap; background: #eef2f2; color: #445; }
.st-novo { background: #e8f1fb; color: #1f4e8c; }
.st-em_analise { background: #efe9fb; color: #5b3a9e; }
.st-aguardando_info, .st-respondido { background: var(--alerta-fundo); color: var(--alerta); }
.st-respondido { background: #ffe1b3; }
.st-na_fila { background: var(--cor-clara); color: var(--cor-escura); }
.st-em_andamento { background: var(--cor); color: #fff; }
.st-em_validacao { background: #fff0c2; color: #7a5a00; }
.st-concluido { background: var(--ok-fundo); color: var(--ok); }
.st-cancelado { background: #eceeee; color: #6b7474; text-decoration: line-through; }
.pr-urgente { background: var(--erro); color: #fff; }
.pr-alta { background: var(--erro-fundo); color: var(--erro); }
.pr-media { background: #fff4e0; color: var(--alerta); }
.pr-baixa { background: #eef2f2; color: #4c5a5a; }
.pr-sem { background: transparent; color: var(--suave); border: 1px dashed #c5d0d0; }
.pr-fila { background: #fff; color: var(--cor); border: 1px solid var(--cor-borda); }
.impacto { font-size: .82rem; color: var(--suave); }
.im-baixo { color: #4c7a5a; } .im-medio { color: #a17a00; } .im-alto { color: #c05600; } .im-critico { color: var(--erro); font-weight: 700; }

/* formulários */
.formulario { display: grid; gap: .9rem; }
label { display: grid; gap: .3rem; font-weight: 600; font-size: .92rem; }
label small { font-weight: 400; color: var(--suave); }
input, select, textarea { font: inherit; font-weight: 400; color: var(--texto); background: #fff; border: 1px solid #c9d6d6; border-radius: 8px; padding: .6rem .7rem; width: 100%; min-height: 42px; }
textarea { resize: vertical; }
input[type=file] { padding: .45rem; background: var(--fundo); }
input[type=checkbox], input[type=radio] { width: auto; min-height: 0; }
.caixa { display: flex; align-items: center; gap: .5rem; }
.duas { display: grid; grid-template-columns: 1fr 1fr; gap: .9rem; }
.acoes { display: flex; justify-content: flex-end; gap: .5rem; flex-wrap: wrap; }
.opcoes { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: .5rem; }
.opcoes legend { font-weight: 600; font-size: .92rem; margin-bottom: .3rem; padding: 0; }
.opcao { display: block; cursor: pointer; }
.opcao input { position: absolute; opacity: 0; pointer-events: none; }
.opcao span { display: inline-block; padding: .5rem 1rem; border: 1px solid #c9d6d6; border-radius: 999px; background: #fff; font-weight: 600; }
.opcao input:checked + span { background: var(--cor); border-color: var(--cor); color: #fff; }
.opcao input:focus-visible + span { outline: 3px solid #7cc4c4; }
.arquivos-escolhidos { color: var(--suave); }

/* filtros */
.filtros { display: grid; grid-template-columns: 2fr repeat(5, 1fr); gap: .6rem; align-items: end; }
.filtros label { font-size: .82rem; }
.filtros-acoes { grid-column: 1 / -1; display: flex; gap: .5rem; justify-content: flex-end; }

/* detalhe */
.detalhe { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 1rem; align-items: start; }
.texto { white-space: pre-wrap; overflow-wrap: anywhere; }
.info { display: grid; grid-template-columns: auto 1fr; gap: .35rem .9rem; margin: 0; font-size: .92rem; }
.info dt { color: var(--suave); }
.info dd { margin: 0; overflow-wrap: anywhere; }
.info-grande { font-size: 1.05rem; }
.senha { font-size: 1.3rem; letter-spacing: .05em; }
.anexos { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: .75rem; }
.anexos li { display: flex; flex-direction: column; gap: .2rem; font-size: .85rem; }
.anexos img { width: 100%; height: 110px; object-fit: cover; border-radius: 8px; border: 1px solid var(--linha); display: block; }
.anexo-pdf { height: 110px; border-radius: 8px; border: 1px solid var(--linha); display: grid; place-items: center; background: var(--erro-fundo); text-decoration: none; }
.anexo-pdf span { color: var(--erro); font-weight: 800; }
.anexo-nome { overflow-wrap: anywhere; }
.anexos small { color: var(--suave); }
.linha-tempo { list-style: none; padding: 0; margin: 0 0 1rem; }
.ev { position: relative; padding: .1rem 0 .9rem 1.4rem; border-left: 2px solid var(--linha); margin-left: .4rem; }
.ev::before { content: ""; position: absolute; left: -7px; top: .35rem; width: 12px; height: 12px; border-radius: 50%; background: #fff; border: 2px solid var(--cor-borda); }
.ev-comentario::before, .ev-validacao::before { background: var(--cor); border-color: var(--cor); }
.ev-cabeca { font-size: .85rem; }
.ev-cabeca time { color: var(--suave); margin-left: .35rem; }
.ev-corpo { font-size: .93rem; }
.ev-corpo .texto { background: var(--fundo); border-radius: 8px; padding: .55rem .75rem; margin-top: .3rem; }
.ev-admin .ev-corpo .texto { background: var(--cor-clara); }
.comentar { border-top: 1px solid var(--linha); padding-top: 1rem; }
.comentar-rodape { display: flex; align-items: center; gap: .75rem; flex-wrap: wrap; }
.comentar-rodape .botao { margin-left: auto; }
.anexar { display: inline-flex; align-items: center; cursor: pointer; color: var(--cor); border: 1px dashed var(--cor-borda); border-radius: 8px; padding: .45rem .8rem; font-weight: 600; }
.anexar input { position: absolute; width: 1px; height: 1px; opacity: 0; }

/* fila */
.fila { list-style: none; padding: 0; margin: 0 0 1.5rem; display: grid; gap: .5rem; }
.fila-item { display: flex; align-items: center; gap: .75rem; background: #fff; border-radius: var(--raio); box-shadow: var(--sombra); padding: .6rem .8rem; }
.fila-item.arrastando { opacity: .5; }
.fila-item.alvo { outline: 2px dashed var(--cor); }
.alca { cursor: grab; color: var(--suave); font-size: 1.2rem; user-select: none; }
.fila-pos { font-weight: 800; color: var(--cor); min-width: 1.6rem; text-align: center; font-size: 1.1rem; }
.fila-titulo { flex: 1; min-width: 0; display: flex; flex-direction: column; text-decoration: none; color: var(--texto); }
.fila-titulo small { color: var(--suave); }
.fila-setas { display: flex; gap: .25rem; margin: 0; }

/* tabela */
.tabela-rolagem { overflow-x: auto; padding: 0; }
.tabela { width: 100%; border-collapse: collapse; font-size: .88rem; }
.tabela th, .tabela td { text-align: left; padding: .5rem .75rem; border-bottom: 1px solid var(--linha); vertical-align: top; }
.tabela th { background: var(--fundo); }
.linha-alerta td { background: #fff7f5; }

/* login */
main.tela-entrar { min-height: 100vh; display: grid; place-items: center; padding: 16px;
  background: linear-gradient(160deg, var(--cor) 0%, var(--cor-escura) 100%); }
.tela-entrar .avisos { width: 100%; max-width: 380px; }
.cartao-entrar { width: 100%; max-width: 380px; padding: 1.75rem; }
.cartao-entrar form { display: grid; gap: .9rem; margin-top: 1rem; }
.marca-grande { color: var(--cor); font-size: 1.3rem; justify-content: center; }
.marca-grande .marca-s { background: var(--cor); color: #fff; }
.cartao-entrar .sub { text-align: center; font-size: .9rem; margin: .4rem 0 0; }
.cartao-entrar .nota { text-align: center; margin: 1rem 0 0; }

/* celular */
@media (max-width: 900px) {
  .detalhe { grid-template-columns: 1fr; }
  .detalhe-lateral { order: -1; }
  .resumo-6 { grid-template-columns: repeat(3, 1fr); }
  .filtros { grid-template-columns: 1fr 1fr; }
  .filtros label:first-child { grid-column: 1 / -1; }
}
@media (max-width: 720px) {
  .menu-botao { display: block; }
  .menu { display: none; position: absolute; top: 56px; left: 0; right: 0; background: var(--cor-escura); flex-direction: column; align-items: stretch; padding: .5rem 16px 1rem; }
  .menu.aberto { display: flex; }
  .menu-sep { display: none; }
  .menu .link { text-align: left; width: 100%; }
  .resumo, .resumo-6 { grid-template-columns: 1fr 1fr; }
  .duas { grid-template-columns: 1fr; }
  .linha { flex-wrap: wrap; gap: .4rem .75rem; }
  .linha-titulo { flex-basis: calc(100% - 4rem); }
  .linha-selos { justify-content: flex-start; width: 100%; }
  .linha-com-acao .linha-titulo { flex-basis: 100%; }
  .fila-item { flex-wrap: wrap; }
  .fila-titulo { flex-basis: calc(100% - 4rem); }
  .fila-item .linha-selos { width: auto; flex: 1; }
  .alca { display: none; }
  .acoes .botao { flex: 1; }
  h1 { font-size: 1.3rem; }
}
