/* ============================================================
   Otimizações mobile globais do funil
   ============================================================ */

/* 1) Evita scroll horizontal acidental em qualquer página */
html, body {
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

/* 2) Inputs com 16px+ — evita zoom automático do iOS ao focar */
input, select, textarea {
  font-size: 16px !important;
  max-width: 100%;
}

/* 3) Touch targets confortáveis (mínimo 44x44px Apple HIG / 48 Material) */
button, a.touch-target, .touch-target, [role="button"] {
  min-height: 44px;
}

/* 4) Imagens e iframes nunca estouram a largura */
img, video, iframe { max-width: 100%; height: auto; }

/* 5) Safe-area pro notch do iPhone */
body {
  padding-left: env(safe-area-inset-left);
  padding-right: env(safe-area-inset-right);
  padding-bottom: env(safe-area-inset-bottom);
}

/* 6) Em telas pequenas, força quebra de palavras longas (CPFs, emails) */
@media (max-width: 480px) {
  * { word-break: break-word; overflow-wrap: anywhere; }
  /* Reduz padding lateral exagerado em containers principais */
  .container, main, .main { padding-left: 12px; padding-right: 12px; }
  /* Botões grandes em mobile */
  button[type="submit"], a[role="button"], .btn-primary, .touch-target {
    min-height: 52px !important;
    font-size: 16px !important;
  }
}

/* 7) Tap highlight discreto (azul horroroso do Android some) */
* { -webkit-tap-highlight-color: rgba(37, 99, 235, 0.15); }

/* 8) Scroll suave */
html { scroll-behavior: smooth; }
