/* ===================================================================
   Reset / base — mobile-first, sem zoom involuntário, toque confortável
   =================================================================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: var(--tamanho-base);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  font-family: var(--fonte-base);
  color: var(--cor-texto);
  background: var(--cor-fundo);
  line-height: 1.5;
  min-height: 100vh;
  overflow-x: hidden; /* nunca permitir scroll lateral */
}

img, picture, svg, video {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

button, input, select, textarea {
  font: inherit;
  color: inherit;
}

/* Em iOS, inputs com font-size < 16px disparam zoom automático ao focar.
   Forçamos 16px mínimo em todos os campos para impedir esse comportamento
   sem precisar travar o zoom geral da página (mantém acessibilidade). */
input, select, textarea, button {
  font-size: 16px;
}

button {
  cursor: pointer;
  border: none;
  background: none;
}

h1, h2, h3, h4 {
  font-family: var(--fonte-titulo);
  line-height: 1.2;
  font-weight: 700;
}

table {
  border-collapse: collapse;
  width: 100%;
}

/* Acessibilidade: respeita preferência do usuário por menos animação */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* Util: esconder visualmente mas manter acessível a leitores de tela */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
