/* Telas de entrar (Tarefa 16). Cores, fonte e raio copiados das variáveis de src/index.css do app; o tema escuro
   vale pelo mesmo atributo data-tema. Nada de estilo próprio. */
:root {
  color-scheme: light;
  --chao: #e4ebf5;
  --painel: #eef3fa;
  --ladrilho: #ffffff;
  --linha: #d3dceb;
  --campo: #6f7d92;
  --tinta: #0f1b2d;
  --suave: #4c5b70;
  --acento: #1f5fd1;
  --acento-forte: #1a4ca8;
  --acento-fundo: #e2eaf7;
  --acento-tinta: #ffffff;
  --perigo: #b42318;
  --perigo-fundo: #fde7e4;
  --radius: 0.75rem;
  --font-body: Inter, ui-sans-serif, system-ui, "Segoe UI", sans-serif;
}
:root[data-tema="escuro"] {
  color-scheme: dark;
  --chao: #121417;
  --painel: #22262b;
  --ladrilho: #1a1d21;
  --linha: #33383f;
  --campo: #8a94a3;
  --tinta: #e8ebf0;
  --suave: #a3adbb;
  --acento: #8db4ff;
  --acento-forte: #a9c6ff;
  --acento-fundo: #1e2c46;
  --acento-tinta: #0d1626;
  --perigo: #ffb4a8;
  --perigo-fundo: #4a1f1b;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
::selection { background: var(--acento-fundo); color: var(--tinta); }
html { -webkit-text-size-adjust: 100%; caret-color: var(--acento); }
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  grid-template-columns: minmax(0, 400px);
  place-content: center;
  padding: 24px 16px;
  background: var(--chao);
  color: var(--tinta);
  font: 15px/1.5 var(--font-body);
  -webkit-font-smoothing: antialiased;
}
main { min-width: 0; padding: 28px 24px; background: var(--ladrilho); border-radius: var(--radius); }
h1 { margin: 0 0 20px; font-size: 20px; line-height: 1.35; font-weight: 700; text-wrap: balance; }
p { margin: 0 0 16px; text-wrap: pretty; }
.produto { margin-bottom: 8px; color: var(--suave); font-size: 13px; font-weight: 600; }

form, .campos, .pilha { display: flex; flex-direction: column; }
.pilha { gap: 10px; }
label { margin-bottom: 6px; font-weight: 600; }
input {
  width: 100%;
  min-height: 44px;
  margin-bottom: 16px;
  padding: 8px 12px;
  background: transparent;
  color: var(--tinta);
  border: 1px solid var(--campo);
  border-radius: calc(var(--radius) - 2px);
  font: 16px var(--font-body);
}
.dica { margin: -8px 0 16px; color: var(--suave); font-size: 13px; }

.botao {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 44px;
  padding: 8px 16px;
  background: var(--acento);
  color: var(--acento-tinta);
  border: 1px solid var(--acento);
  border-radius: calc(var(--radius) - 2px);
  font: 600 15px var(--font-body);
  text-align: center;
  text-decoration: none;
  overflow-wrap: anywhere;
  cursor: pointer;
  touch-action: manipulation;
}
.botao:hover { background: var(--acento-forte); border-color: var(--acento-forte); }
.botao.secundario { background: transparent; color: var(--tinta); border-color: var(--campo); }
.botao.secundario:hover { background: var(--painel); }
.botao:disabled, .botao[aria-disabled="true"] { opacity: 0.6; cursor: progress; }
/* só aparece se o programa da tela não chegar em 6 s (ele apaga a linha ao carregar); fora do fluxo, para a tela não pular */
.espera {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: 16px;
  margin: 0;
  text-align: center;
  color: var(--suave);
  visibility: hidden;
  animation: aparecer 0s linear 6s forwards;
}
@keyframes aparecer { to { visibility: visible; } }
:focus-visible { outline: 2px solid var(--acento); outline-offset: 2px; }

.quem {
  display: flex;
  flex-direction: column;
  margin-bottom: 20px;
  padding: 12px;
  background: var(--painel);
  border-radius: calc(var(--radius) - 2px);
  overflow-wrap: anywhere;
}
.quem span { color: var(--suave); }

.aviso {
  margin: 16px 0 0;
  padding: 10px 12px;
  background: var(--perigo-fundo);
  color: var(--perigo);
  border-radius: calc(var(--radius) - 2px);
}
.aviso:empty { margin: 0; padding: 0; }
.rodape { margin: 20px 0 0; padding-top: 16px; border-top: 1px solid var(--linha); color: var(--suave); font-size: 13px; }
a { color: var(--acento); text-underline-offset: 3px; }
a.botao { color: var(--acento-tinta); }
