/* Janela "Instalar o app" (instalar-app.js) */
.ia-fundo {
  position: fixed; inset: 0; z-index: 1000;
  display: flex; align-items: center; justify-content: center;
  padding: 16px; background: rgba(28, 38, 30, .45);
  animation: ia-aparece .2s ease-out;
}
.ia-caixa {
  position: relative; width: 100%; max-width: 420px;
  max-height: calc(100vh - 32px); overflow-y: auto;
  background: #fff; color: var(--char, #2C2C2C);
  border-radius: 16px; padding: 22px 22px 18px;
  box-shadow: 0 18px 48px rgba(0, 0, 0, .22);
}
.ia-x {
  position: absolute; top: 8px; right: 8px; width: 40px; height: 40px;
  border: 0; border-radius: 10px; background: transparent;
  color: var(--mid, #6B6B6B); font-size: 1.5rem; line-height: 1; cursor: pointer;
}
.ia-x:hover { background: var(--sage-light, #EEF3EE); }
.ia-topo { display: flex; align-items: center; gap: 14px; padding-right: 28px; }
.ia-topo img {
  flex: 0 0 auto; width: 56px; height: 56px; border-radius: 14px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .12);
}
.ia-topo h2 { margin: 0 0 4px; font-size: 1.12rem; color: var(--sage-dark, #4A6B4E); }
.ia-topo p { margin: 0; font-size: .88rem; line-height: 1.4; color: var(--mid, #6B6B6B); }
.ia-texto { margin: 16px 0 0; font-size: .92rem; line-height: 1.5; }
.ia-passos { margin: 16px 0 0; padding: 0; list-style: none; counter-reset: ia-passo; }
.ia-passos li {
  position: relative; counter-increment: ia-passo;
  padding: 0 0 12px 38px; font-size: .92rem; line-height: 1.45;
}
.ia-passos li::before {
  content: counter(ia-passo);
  position: absolute; left: 0; top: -1px; width: 26px; height: 26px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%; background: var(--sage-light, #EEF3EE);
  color: var(--sage-dark, #4A6B4E); font-size: .85rem; font-weight: 700;
}
.ia-icone { display: inline-block; width: 20px; height: 20px; vertical-align: -4px; color: #007AFF; }
.ia-dica {
  margin: 2px 0 0; padding: 10px 12px; border-radius: 10px;
  background: var(--cream, #FDFAF5); border: 1px solid var(--light, #E4E4E0);
  font-size: .8rem; line-height: 1.4; color: var(--mid, #6B6B6B);
}
.ia-acoes { display: flex; flex-direction: column; gap: 8px; margin-top: 16px; }
.ia-acoes button { min-height: 44px; border-radius: 10px; font: inherit; font-weight: 600; cursor: pointer; }
.ia-instalar { border: 0; background: var(--sage-dark, #4A6B4E); color: #fff; font-size: 1rem; }
.ia-instalar:hover { background: #3d5a40; }
.ia-secundario { border: 1px solid var(--light, #E4E4E0); background: transparent; color: var(--mid, #6B6B6B); }
.ia-secundario:hover { background: var(--sage-light, #EEF3EE); }
.ia-aviso {
  position: fixed; left: 50%; bottom: 20px; z-index: 1001; transform: translateX(-50%);
  width: max-content; max-width: calc(100vw - 32px);
  padding: 12px 16px; border-radius: 12px;
  background: var(--char, #2C2C2C); color: #fff; font-size: .9rem; line-height: 1.4;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .25); transition: opacity .3s;
}
.ia-aviso.ia-sai { opacity: 0; }
@keyframes ia-aparece { from { opacity: 0; } to { opacity: 1; } }
@keyframes ia-sobe { from { transform: translateY(24px); } to { transform: none; } }
@media (max-width: 600px) {
  .ia-fundo { align-items: flex-end; padding: 0; }
  .ia-caixa {
    max-width: none; max-height: 85vh; border-radius: 18px 18px 0 0;
    padding-bottom: calc(18px + env(safe-area-inset-bottom, 0px));
    animation: ia-sobe .25s ease-out;
  }
}
@media (prefers-reduced-motion: reduce) {
  .ia-fundo, .ia-caixa { animation: none; }
}
