/*
  Estilos da tela de boas-vindas (#modalWelcome).
  Página independente (boas-vindas/index.html), fora do fluxo do site principal.
*/

/* ── Contêiner e fundo ────────────────────────────────────────────────── */
#modalWelcome {
  position: fixed;
  inset: 0;
  z-index: 99997;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  overflow: hidden;
  background:
    radial-gradient(circle at top right, #EEF9FA, transparent 45%),
    radial-gradient(circle at bottom left, #FFF7F0, transparent 35%),
    #FAFAFA;
}

/* ── Blobs decorativos ────────────────────────────────────────────────── */
#modalWelcome .wel-blobs { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
#modalWelcome .wel-blob { position: absolute; border-radius: 50%; filter: blur(8px); }
#modalWelcome .wel-blob-1 { width: 340px; height: 340px; top: -90px; right: -70px; background: var(--verde); opacity: .035; }
#modalWelcome .wel-blob-2 { width: 300px; height: 300px; bottom: -80px; left: -90px; background: var(--dourado); opacity: .03; }
#modalWelcome .wel-blob-3 { width: 220px; height: 220px; top: 38%; left: -120px; background: var(--verde); opacity: .025; }

/* ── Tela (passo) base ────────────────────────────────────────────────── */
#modalWelcome .wel-tela {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 400px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  transform: translateY(-52px);
}
#modalWelcome .wel-tela.is-out { animation: wel-fadeout .3s ease forwards; }
@keyframes wel-fadeout { to { opacity: 0; } }

/* ── Tela 1: Bem-vindo ────────────────────────────────────────────────── */
#modalWelcome[data-tela="1"] .wel-tela { transform: none; padding-bottom: 250px; }
@media (max-height: 700px) { #modalWelcome[data-tela="1"] .wel-tela { padding-bottom: 190px; } }

#modalWelcome .wel-logo { width: 187px; height: auto; object-fit: contain; margin-bottom: 30px; }
#modalWelcome .wel-ola { font-size: 1.6rem; font-weight: 700; color: var(--bordo); margin-bottom: 14px; line-height: 1.25; text-wrap: balance; }
#modalWelcome [data-wel="1"] .wel-ola { font-size: 1.9rem; font-weight: 800; margin-bottom: 10px; line-height: 1.15; letter-spacing: -.02em; }
#modalWelcome .wel-lead { font-size: 1.05rem; font-weight: 600; color: var(--verde); margin-bottom: 22px; }
#modalWelcome .wel-txt { font-size: .95rem; color: #4a4f54; line-height: 1.62; max-width: 260px; margin: 0 auto; text-wrap: balance; }

#modalWelcome .footer-cobasi {
  position: fixed;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 118%;
  max-width: none;
  height: auto;
  min-height: 230px;
  object-fit: cover;
  object-position: center bottom;
  pointer-events: none;
  user-select: none;
  z-index: 1;
  display: none;
}
#modalWelcome[data-tela="1"] .footer-cobasi { display: block; }
@media (min-width: 390px) { #modalWelcome .footer-cobasi { width: 112%; } }
@media (max-height: 700px) { #modalWelcome .footer-cobasi { width: 105%; min-height: 190px; } }
#modalWelcome[data-anim="1"] .footer-cobasi { animation: footerEnter 700ms ease-out .3s both; }
@keyframes footerEnter { from { opacity: 0; transform: translate(-50%, 30px); } to { opacity: 1; transform: translate(-50%, 0); } }

/* ── Tela 2: Cobasi Já ────────────────────────────────────────────────── */
#modalWelcome[data-tela="2"] .wel-tela { transform: none; padding-bottom: 0; }
#modalWelcome .wel-logo-ja { width: 140px; margin-bottom: 28px; }
#modalWelcome .wel-ola-2 { display: flex; flex-direction: column; gap: 2px; margin-bottom: 26px; letter-spacing: -.01em; text-wrap: balance; }
#modalWelcome .wel-ola-2 .l1 { font-size: 1.35rem; font-weight: 700; color: var(--bordo); line-height: 1.2; }
#modalWelcome .wel-ola-2 .l2 { font-size: 1.7rem; font-weight: 800; color: var(--bordo); line-height: 1.15; }
#modalWelcome .wel-ola-2 em { font-style: normal; color: var(--verde); }
#modalWelcome [data-wel="2"] .wel-txt { max-width: 300px; margin-bottom: 0; color: #4a4f54; }
#modalWelcome [data-wel="2"] .wel-txt em { font-style: normal; color: var(--verde); font-weight: 600; }
#modalWelcome .wel-nota { font-size: .72rem; color: var(--cinza-claro); margin-top: 18px; max-width: 300px; line-height: 1.5; }
#modalWelcome [data-wel="2"] .wel-nota { font-size: 11px; margin-top: 20px; max-width: 280px; }

/* ── Indicadores de progresso (dots) ──────────────────────────────────── */
#modalWelcome .wel-dots { display: flex; gap: 8px; justify-content: center; margin: 30px auto 28px; }
#modalWelcome .wel-dots-2 { margin: 34px auto 30px; }
#modalWelcome .wel-dot { width: 7px; height: 7px; border-radius: 50%; background: transparent; border: 1.5px solid var(--verde); opacity: .45; transition: .25s; }
#modalWelcome .wel-dot.on { background: var(--verde); border-color: var(--verde); opacity: 1; width: 20px; border-radius: 20px; }

/* ── Botões de ação ───────────────────────────────────────────────────── */
#modalWelcome .wel-btn {
  height: 56px;
  background: var(--verde);
  color: #fff;
  border: none;
  border-radius: 16px;
  padding: 0 44px;
  font-size: 1.05rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(0, 145, 170, .18);
  transition: transform .25s, box-shadow .25s;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
#modalWelcome .wel-btn:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(0, 145, 170, .24); }
#modalWelcome .wel-btn:active { transform: translateY(0); }
#modalWelcome .wel-btn-2 { width: 240px; padding: 0; border-radius: 18px; }
#modalWelcome .wel-btn-2:hover { transform: translateY(-2px) scale(1.02); }

/* ── Animações de entrada por elemento ────────────────────────────────── */
#modalWelcome .wel-tela.is-anim .wel-logo { animation: wel-logo-in .55s ease both; }
#modalWelcome .wel-tela.is-anim .wel-ola { animation: wel-fade-up .5s ease .16s both; }
#modalWelcome .wel-tela.is-anim .wel-lead { animation: wel-fade-up .5s ease .26s both; }
#modalWelcome .wel-tela.is-anim .wel-txt { animation: wel-fade-up .5s ease .34s both; }
#modalWelcome .wel-tela.is-anim .wel-sep { animation: wel-fade-up .5s ease .44s both; }
#modalWelcome .wel-tela.is-anim .wel-dots { animation: wel-fade-up .5s ease .44s both; }
#modalWelcome .wel-tela.is-anim .wel-btn { animation: wel-fade-up .5s ease .54s both; }
#modalWelcome .wel-tela.is-anim .wel-nota { animation: wel-fade-up .5s ease .64s both; }
@keyframes wel-logo-in { from { opacity: 0; transform: scale(.95); } to { opacity: 1; transform: scale(1); } }
@keyframes wel-fade-up { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  #modalWelcome * { animation: none !important; }
}
