/* Inter (licença OFL), servida do próprio projeto: a CSP só aceita arquivos do mesmo servidor */
@font-face { font-family: "Inter"; font-weight: 400; font-style: normal; font-display: swap; src: url("/fonts/inter-latin-400.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 600; font-style: normal; font-display: swap; src: url("/fonts/inter-latin-600.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 700; font-style: normal; font-display: swap; src: url("/fonts/inter-latin-700.woff2") format("woff2"); }
:root { --azul: #1f4e79; --borda: #dee2e6; }
* { box-sizing: border-box; }
body { font-family: "Inter", "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif; margin: 0; color: #212529; }
main { max-width: 900px; margin: 0 auto; padding: 12px; }

button { font: inherit; cursor: pointer; border-radius: 6px; border: 1px solid #999; background: #fff; padding: 8px 14px; }
.azul { background: var(--azul); border-color: var(--azul); color: #fff; }
.grande { flex: 1; }
.barra { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 8px; }
.vazio { padding: 16px; color: #6c757d; text-align: center; }

/* Tela do sistema (depois do login) */
body.sistema { background: #f0f0f0; overflow: hidden; }
.janela { display: flex; flex-direction: column; height: 100vh; font-family: "Inter", "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif; -webkit-font-smoothing: antialiased; }

.barra-local { display: flex; align-items: center; gap: 12px; padding: 4px 8px; background: #f0f0f0; border-bottom: 1px solid #b8bec8; }
.saudacao { font-size: 1rem; white-space: nowrap; color: #1f2937; }
.onde { flex: 1; text-align: left; font: inherit; color: #fff; background: #3399ff; border: 1px solid #1c7ae0; border-radius: 0; padding: 3px 6px; }
.onde option { background: #fff; color: #000; }

.area { display: flex; flex: 1; min-height: 0; }
.lateral { width: 124px; flex: none; overflow-y: auto; background: #f0f0f0; border-right: 2px solid #b8bec8; }
.lateral button { display: block; width: 100%; border: 0; border-bottom: 1px solid #d3d7de; border-radius: 0; background: #f7f8fa; padding: 7px 4px; font: inherit; font-size: .88rem; text-align: center; color: #1f2937; }
.lateral button:hover { background: #dbe6f5; }
.lateral .grupo { font-weight: 700; background: #ebebeb; border-top: 1px solid #fff; }
.lateral section + section { margin-top: 2px; }

[hidden] { display: none !important; }
.conteudo { flex: 1; min-width: 0; max-width: none; margin: 0; background: #fff; padding: 0; overflow: auto; position: relative; }
/* Imagem de fundo (empresas.logo): a área inteira é branca e o logo fica no canto superior esquerdo,
   com posição e tamanho proporcionais à área (acompanha o tamanho da tela). */
.conteudo { background: #fff; }
.logo { position: absolute; top: 4.5%; left: 6.9%; width: 14.7%; height: auto; max-width: none; z-index: 0; pointer-events: none; }
.conteudo .vazio { position: relative; z-index: 1; }
.logo.cheia { top: 0; left: 0; width: 100%; height: 100%; object-fit: fill; }
.rodape-app { display: flex; align-items: center; justify-content: space-between; padding: 4px 12px; background: #f0f0f0; border-top: 1px solid #b8bec8; }
.script { font-family: "Brush Script MT", "Segoe Script", cursive; font-size: 1.7rem; margin: 0 auto; }
.sair { border: 0; background: none; font: inherit; font-weight: 700; padding: 2px 8px; }

@media (max-width: 700px) {
  .barra-local { flex-direction: column; align-items: stretch; gap: 4px; }
  .saudacao { white-space: normal; font-size: .95rem; }
  .area { flex-direction: column; }
  .lateral { width: auto; border-right: 0; border-bottom: 2px solid #b8bec8; max-height: 40vh; }
  .conteudo { padding: 12px; }
  body.sistema { overflow: auto; }
  .janela { min-height: 100vh; height: auto; }
}

.login { background: #f1f3f5; }
.cartao { max-width: 340px; margin: 15vh auto 0; padding: 24px; background: #fff; border: 1px solid var(--borda); border-radius: 8px; }
.cartao h1 { margin: 0 0 16px; font-size: 1.4rem; }
.cartao label { display: block; margin-bottom: 12px; }
.cartao input { display: block; width: 100%; padding: 8px; margin-top: 4px; font: inherit; border: 1px solid var(--borda); border-radius: 6px; }
.cartao button { width: 100%; padding: 10px; }
.erro { color: #dc3545; margin: 0 0 12px; }
