/* ============================================================
   Competição de Fantasias — Laura 5 anos
   Linguagem visual extraída do convite: adesivo 3D, contorno
   grosso roxo-escuro, sombra dura, noite de Halloween.
   ============================================================ */

:root {
  /* noite */
  --night-0: #140627;
  --night-1: #241049;
  --night-2: #3a1a6e;
  --night-3: #512394;

  /* cores do convite */
  --pink:        #ff2e9a;
  --pink-light:  #ff79c4;
  --pink-deep:   #cc0f72;
  --purple:      #9d4edd;
  --purple-deep: #6a1fa8;
  --purple-ink:  #2d0b52;
  --orange:      #ff8a1e;
  --orange-deep: #ef5f07;
  --amber:       #ffc63d;
  --cream:       #fff4dc;
  --parchment:   #fdf2d8;
  --parchment-2: #f6e3bc;

  --ink:      #3b1764;
  --ink-soft: #6b4a93;

  --ring: 0 0 0 4px rgba(255, 46, 154, .35);
  --r-sm: 14px;
  --r-md: 22px;
  --r-lg: 32px;

  --font-fun: 'Baloo 2', 'Fredoka', 'Trebuchet MS', system-ui, sans-serif;
  --font-ui:  'Fredoka', 'Baloo 2', system-ui, -apple-system, sans-serif;
}

/* ------------------------------------------------------------------ reset */

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100dvh;
  font-family: var(--font-ui);
  font-size: 17px;
  line-height: 1.5;
  color: var(--cream);
  background: var(--night-0);
  overflow-x: hidden;
  padding:
    env(safe-area-inset-top, 0px) env(safe-area-inset-right, 0px)
    env(safe-area-inset-bottom, 0px) env(safe-area-inset-left, 0px);
}

img { max-width: 100%; display: block; }
[hidden] { display: none !important; }
button, input, textarea, select { font: inherit; color: inherit; }

/* ======================================================== CÉU DE HALLOWEEN */

.sky { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }

.sky::before {
  content: '';
  position: absolute; inset: 0;
  background:
    radial-gradient(90% 60% at 82% 6%, rgba(255, 220, 140, .22), transparent 55%),
    radial-gradient(80% 50% at 15% 95%, rgba(255, 138, 30, .20), transparent 60%),
    linear-gradient(170deg, var(--night-2) 0%, var(--night-1) 45%, var(--night-0) 100%);
}

/* lua */
.moon {
  position: absolute; top: 3vh; right: 7vw;
  width: clamp(70px, 13vw, 140px); aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle at 36% 32%, #fffdf2, #ffeab0 58%, #f4cf7a);
  box-shadow: 0 0 60px 18px rgba(255, 225, 150, .30), 0 0 140px 50px rgba(255, 200, 100, .14);
}
.moon::after {
  content: ''; position: absolute; inset: 0; border-radius: 50%;
  background:
    radial-gradient(circle at 62% 30%, rgba(214, 184, 120, .55) 0 9%, transparent 10%),
    radial-gradient(circle at 38% 62%, rgba(214, 184, 120, .45) 0 13%, transparent 14%),
    radial-gradient(circle at 72% 68%, rgba(214, 184, 120, .40) 0 7%, transparent 8%);
}

/* estrelinhas */
.star-dot {
  position: absolute; width: 4px; height: 4px; border-radius: 50%;
  background: #fff6cf;
  box-shadow: 0 0 7px 2px rgba(255, 246, 207, .85);
  animation: twinkle 3.4s ease-in-out infinite;
}
@keyframes twinkle {
  0%, 100% { opacity: .25; transform: scale(.65); }
  50%      { opacity: 1;   transform: scale(1.25); }
}

/* morcegos voando */
.bat {
  position: absolute;
  width: clamp(26px, 4vw, 46px);
  animation: fly linear infinite;
  will-change: transform;
}
.bat svg { width: 100%; height: auto; display: block; filter: drop-shadow(0 3px 5px rgba(0,0,0,.45)); }
.bat .wing { transform-origin: 50% 55%; animation: flap .42s ease-in-out infinite alternate; }
@keyframes flap { from { transform: scaleY(1) scaleX(1); } to { transform: scaleY(.55) scaleX(1.06); } }
@keyframes fly {
  0%   { transform: translate(-16vw, 0) rotate(-6deg); }
  25%  { transform: translate(14vw, -7vh) rotate(5deg); }
  50%  { transform: translate(46vw, 3vh) rotate(-4deg); }
  75%  { transform: translate(78vw, -6vh) rotate(6deg); }
  100% { transform: translate(116vw, 1vh) rotate(-5deg); }
}

/* fantasminhas subindo */
.ghostie {
  position: absolute; bottom: -90px;
  width: clamp(34px, 5vw, 58px);
  opacity: .42;
  animation: float-up linear infinite;
}
@keyframes float-up {
  0%   { transform: translateY(0) translateX(0) scale(.8); opacity: 0; }
  12%  { opacity: .5; }
  50%  { transform: translateY(-52vh) translateX(26px) scale(1); }
  88%  { opacity: .34; }
  100% { transform: translateY(-112vh) translateX(-18px) scale(1.12); opacity: 0; }
}

/* fileira de abóboras no rodapé */
.pumpkin-row {
  position: absolute; left: 0; right: 0; bottom: -10px;
  display: flex; justify-content: space-around; align-items: flex-end;
  opacity: .5;
}
.pumpkin-row svg { width: clamp(52px, 9vw, 104px); height: auto; }
.pumpkin-row > * { animation: glow-pumpkin 3.6s ease-in-out infinite; }
@keyframes glow-pumpkin {
  0%, 100% { filter: drop-shadow(0 0 10px rgba(255, 140, 30, .55)); }
  50%      { filter: drop-shadow(0 0 26px rgba(255, 180, 60, .95)); }
}

/* varalzinho de luzes */
.lights { position: absolute; top: 0; left: 0; right: 0; height: 56px; }
.lights svg { width: 100%; height: 100%; }
.lights .bulb { animation: bulb 2.6s ease-in-out infinite; }
@keyframes bulb { 0%, 100% { opacity: .45; } 50% { opacity: 1; } }

/* teias nos cantos */
.web { position: absolute; width: clamp(90px, 16vw, 190px); opacity: .17; }
.web.tl { top: 0; left: 0; }
.web.tr { top: 0; right: 0; transform: scaleX(-1); }

@media (prefers-reduced-motion: reduce) {
  .bat, .ghostie, .star-dot, .pumpkin-row > *, .lights .bulb, .bat .wing {
    animation: none !important;
  }
  .bat { display: none; }
}

/* ============================================================== TIPOGRAFIA */

h1, h2, h3, .fun { font-family: var(--font-fun); font-weight: 800; line-height: 1.08; margin: 0; }

/* texto estilo adesivo, igual ao convite */
.sticker-text {
  color: var(--pink);
  -webkit-text-stroke: 2px var(--purple-ink);
  paint-order: stroke fill;
  text-shadow:
    0 2px 0 var(--pink-deep),
    0 4px 0 var(--purple-ink),
    0 9px 18px rgba(0, 0, 0, .45);
  letter-spacing: .01em;
}
.sticker-text.roxo  { color: var(--purple); text-shadow: 0 2px 0 var(--purple-deep), 0 4px 0 #22063f, 0 9px 18px rgba(0,0,0,.45); }
.sticker-text.laranja { color: var(--orange); text-shadow: 0 2px 0 var(--orange-deep), 0 4px 0 #6d2a00, 0 9px 18px rgba(0,0,0,.45); }

.subtitulo {
  font-family: var(--font-fun);
  font-weight: 700;
  color: var(--cream);
  text-shadow: 0 2px 6px rgba(0, 0, 0, .5);
}

/* faixa roxa riscada (igual "Vai ser assustadoramente divertida!") */
.faixa {
  display: inline-block;
  padding: .3em .95em .42em;
  background: var(--purple-deep);
  border-radius: 999px;
  color: var(--cream);
  font-family: var(--font-fun);
  font-weight: 700;
  transform: rotate(-1.2deg);
  box-shadow: 0 4px 0 #2a0a4d, 0 10px 22px rgba(0, 0, 0, .35);
}

/* ================================================================ LAYOUT */

.wrap {
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
  padding-inline: 18px;
  padding-block: 20px 120px;
  position: relative;
}

.topbar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px 0 18px;
}
.marca { display: flex; align-items: center; gap: 9px; font-family: var(--font-fun); font-weight: 800; }
.marca .emoji { font-size: 1.5rem; filter: drop-shadow(0 2px 4px rgba(0,0,0,.5)); }
.marca span { font-size: 1.02rem; color: var(--cream); text-shadow: 0 2px 5px rgba(0,0,0,.6); }

/* o botao de som fica por cima da lua: precisa de fundo solido */
#btn-som {
  background: rgba(20, 6, 39, .82);
  border-color: rgba(255, 255, 255, .3);
  backdrop-filter: blur(6px);
}

/* ================================================================= CARDS */

.card {
  background: linear-gradient(165deg, rgba(90, 44, 150, .92), rgba(52, 22, 98, .95));
  border: 3px solid var(--purple-ink);
  border-radius: var(--r-lg);
  box-shadow: 0 7px 0 var(--purple-ink), 0 18px 40px rgba(0, 0, 0, .45);
  padding: 22px;
}

/* o pergaminho do convite */
.pergaminho {
  background:
    radial-gradient(120% 90% at 50% 0%, #fffaf0, transparent 60%),
    linear-gradient(170deg, var(--parchment) 0%, var(--parchment-2) 100%);
  border: 3px solid #c9a86b;
  border-radius: var(--r-lg);
  box-shadow: 0 7px 0 #a8863f, 0 20px 44px rgba(0, 0, 0, .5);
  color: var(--ink);
  padding: 24px 20px;
  position: relative;
}
.pergaminho h1, .pergaminho h2, .pergaminho h3 { color: var(--purple-deep); }
.pergaminho .ajuda { color: var(--ink-soft); }

/* ============================================================== BOTÕES */

.btn {
  --b: var(--purple-ink);
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  width: 100%;
  min-height: 60px;
  padding: 14px 22px;
  font-family: var(--font-fun);
  font-weight: 800;
  font-size: 1.14rem;
  color: #fff;
  background: linear-gradient(180deg, var(--pink-light), var(--pink) 55%, var(--pink-deep));
  border: 3px solid var(--b);
  border-radius: 999px;
  box-shadow: 0 6px 0 var(--b), 0 12px 26px rgba(0, 0, 0, .38);
  text-shadow: 0 2px 3px rgba(0, 0, 0, .3);
  text-decoration: none;
  cursor: pointer;
  transition: transform .09s ease, box-shadow .09s ease, filter .15s ease;
}
.btn:active {
  transform: translateY(5px);
  box-shadow: 0 1px 0 var(--b), 0 5px 12px rgba(0, 0, 0, .35);
}
.btn:focus-visible { outline: none; box-shadow: 0 6px 0 var(--b), var(--ring); }
.btn[disabled] { opacity: .5; cursor: not-allowed; filter: grayscale(.45); }

.btn.laranja { background: linear-gradient(180deg, #ffc077, var(--orange) 55%, var(--orange-deep)); }
.btn.roxo    { background: linear-gradient(180deg, #c491f0, var(--purple) 55%, var(--purple-deep)); }
.btn.creme   { background: linear-gradient(180deg, #fffdf6, var(--parchment) 60%, #e8d0a2); color: var(--purple-deep); text-shadow: none; }
.btn.fantasma {
  background: rgba(255, 255, 255, .08);
  border-color: rgba(255, 255, 255, .34);
  box-shadow: 0 5px 0 rgba(0, 0, 0, .3);
  color: var(--cream);
  font-size: 1rem; min-height: 50px;
}
.btn.pequeno { min-height: 44px; font-size: .96rem; padding: 8px 16px; width: auto; }

.btn-linha { display: flex; gap: 10px; flex-wrap: wrap; }
.btn-linha > .btn { flex: 1 1 160px; width: auto; }

/* ============================================================== FORMULÁRIO */

.campo { margin-bottom: 18px; }
.campo label {
  display: block;
  font-family: var(--font-fun); font-weight: 700; font-size: 1rem;
  margin-bottom: 7px; color: var(--purple-deep);
}
.campo .ajuda { font-size: .86rem; font-weight: 400; margin-top: 5px; }

.input {
  width: 100%;
  min-height: 56px;
  padding: 12px 16px;
  background: #fffdf6;
  border: 3px solid #d8b878;
  border-radius: var(--r-sm);
  color: var(--ink);
  font-size: 1.05rem;
  box-shadow: inset 0 3px 7px rgba(140, 100, 40, .13);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.input::placeholder { color: #b09a74; }
.input:focus { outline: none; border-color: var(--pink); box-shadow: var(--ring); }
textarea.input { min-height: 92px; resize: vertical; line-height: 1.45; }

.dupla { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 520px) { .dupla { grid-template-columns: 1fr; } }

/* escolha competidor / só votar */
.escolha { display: grid; gap: 11px; }
.escolha label {
  display: flex; align-items: center; gap: 13px;
  padding: 15px 17px;
  background: #fffdf6;
  border: 3px solid #d8b878;
  border-radius: var(--r-md);
  cursor: pointer;
  color: var(--ink);
  font-weight: 500; font-size: .99rem;
  transition: all .14s ease;
}
.escolha label .ico { font-size: 1.7rem; line-height: 1; }
.escolha label strong { display: block; font-family: var(--font-fun); font-size: 1.05rem; color: var(--purple-deep); }
.escolha input { position: absolute; opacity: 0; pointer-events: none; }
.escolha input:checked + label,
.escolha label:has(input:checked) {
  border-color: var(--pink);
  background: linear-gradient(180deg, #fff2f9, #ffe3f1);
  box-shadow: 0 5px 0 var(--pink-deep);
  transform: translateY(-2px);
}

/* ================================================================== FOTO */

.foto-box {
  position: relative;
  aspect-ratio: 3 / 4;
  max-height: 60vh;
  margin-inline: auto;
  width: 100%;
  border-radius: var(--r-lg);
  overflow: hidden;
  background: linear-gradient(165deg, #3b1a70, #230d47);
  border: 4px solid var(--purple-ink);
  box-shadow: 0 7px 0 var(--purple-ink), 0 18px 40px rgba(0, 0, 0, .5);
  display: grid; place-items: center;
}
.foto-box img { width: 100%; height: 100%; object-fit: cover; }
.foto-box .vazio { text-align: center; padding: 26px; color: #d9c6f2; }
.foto-box .vazio .big { font-size: 3.6rem; display: block; margin-bottom: 8px; }

/* moldura decorativa sobre a foto */
.foto-box .moldura { position: absolute; inset: 0; pointer-events: none; }
.foto-box .moldura::after {
  content: '';
  position: absolute; inset: 7px;
  border: 3px dashed rgba(255, 198, 61, .55);
  border-radius: calc(var(--r-lg) - 10px);
}

/* =============================================================== GALERIA */

.galeria {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 14px;
}

.fantasia-card {
  position: relative;
  background: linear-gradient(165deg, rgba(96, 48, 158, .95), rgba(48, 20, 92, .97));
  border: 3px solid var(--purple-ink);
  border-radius: var(--r-md);
  box-shadow: 0 5px 0 var(--purple-ink), 0 12px 26px rgba(0, 0, 0, .4);
  overflow: hidden;
  display: flex; flex-direction: column;
}
.fantasia-card .thumb {
  aspect-ratio: 3 / 4; width: 100%; object-fit: cover;
  background: #2a0f55;
}
.fantasia-card .sem-foto {
  aspect-ratio: 3 / 4; display: grid; place-items: center;
  font-size: 2.6rem; background: linear-gradient(165deg, #431d80, #280f52); opacity: .7;
}
.fantasia-card .info { padding: 10px 12px 12px; }
.fantasia-card .nome {
  font-family: var(--font-fun); font-weight: 800; font-size: 1.02rem;
  color: var(--cream); line-height: 1.15;
}
.fantasia-card .fantasia {
  font-size: .85rem; color: var(--amber); font-weight: 600; margin-top: 2px;
}
.fantasia-card.eu { border-color: var(--amber); box-shadow: 0 5px 0 #a8762a, 0 12px 26px rgba(0,0,0,.4); }

.etiqueta {
  position: absolute; top: 9px; left: 9px; z-index: 2;
  padding: 4px 11px;
  font-family: var(--font-fun); font-weight: 800; font-size: .74rem;
  border-radius: 999px;
  border: 2px solid var(--purple-ink);
  background: var(--amber); color: #4a2500;
  box-shadow: 0 3px 0 rgba(0, 0, 0, .3);
}
.etiqueta.ok { background: #46d17f; color: #0b3d22; }

/* ========================================================== VOTO ÚNICO */

/* contagem regressiva até a votação abrir */
.aguardando .relogio { font-size: 3rem; line-height: 1; margin-bottom: 4px; }
.contador-grande {
  font-family: var(--font-fun); font-weight: 800;
  font-size: clamp(2.2rem, 11vw, 3.2rem);
  color: var(--amber);
  text-shadow: 0 3px 0 #7a4a00, 0 7px 18px rgba(0, 0, 0, .5);
  margin: 10px 0 14px;
  font-variant-numeric: tabular-nums;
}

.destaque-aberta {
  border-color: var(--amber);
  box-shadow: 0 7px 0 #a8762a, 0 0 40px rgba(255, 198, 61, .3);
  animation: respira 2.8s ease-in-out infinite;
}
@keyframes respira {
  0%, 100% { box-shadow: 0 7px 0 #a8762a, 0 0 36px rgba(255, 198, 61, .26); }
  50%      { box-shadow: 0 7px 0 #a8762a, 0 0 58px rgba(255, 198, 61, .5); }
}

/* o card "tu votou em..." */
.voto-escolhido {
  display: flex; align-items: center; gap: 14px; text-align: left;
  padding: 12px; border-radius: var(--r-md);
  background: rgba(0, 0, 0, .26);
  border: 3px solid var(--amber);
}
.voto-escolhido img, .voto-escolhido .sem {
  flex: none; width: 72px; height: 94px; object-fit: cover;
  border-radius: 14px; border: 2px solid var(--purple-ink); background: #2a0f55;
  display: grid; place-items: center; font-size: 2rem;
}

.miniatura {
  flex: none; width: 86px; height: 112px; border-radius: 16px; overflow: hidden;
  border: 3px solid var(--purple-ink); background: #2a0f55;
  display: grid; place-items: center;
}
.miniatura img { width: 100%; height: 100%; object-fit: cover; }

/* o card vira botão na tela de votação */
button.fantasia-card {
  font: inherit; color: inherit; text-align: left; padding: 0;
  cursor: pointer; width: 100%;
  transition: transform .13s ease, box-shadow .13s ease;
}
button.fantasia-card:active { transform: translateY(4px); box-shadow: 0 1px 0 var(--purple-ink); }
.fantasia-card.escolhido {
  border-color: var(--amber);
  box-shadow: 0 5px 0 #a8762a, 0 0 26px rgba(255, 198, 61, .4);
}

/* confirmação do voto */
.modal {
  position: fixed; inset: 0; z-index: 120;
  display: grid; place-items: center; padding: 18px;
  background: rgba(10, 3, 22, .82);
  backdrop-filter: blur(5px);
  opacity: 0; transition: opacity .22s ease;
}
.modal.abre { opacity: 1; }
.modal-caixa {
  width: min(94vw, 400px);
  max-height: 92dvh; overflow-y: auto;
  padding: 20px;
  text-align: center;
  background: linear-gradient(165deg, rgba(96, 48, 158, .97), rgba(48, 20, 92, .98));
  border: 3px solid var(--purple-ink);
  border-radius: var(--r-lg);
  box-shadow: 0 8px 0 var(--purple-ink), 0 22px 50px rgba(0, 0, 0, .6);
  transform: scale(.9) translateY(14px);
  transition: transform .26s cubic-bezier(.34, 1.56, .64, 1);
}
.modal.abre .modal-caixa { transform: scale(1) translateY(0); }
.modal-caixa img {
  width: 100%; max-height: 42dvh; object-fit: contain;
  border-radius: var(--r-md); background: #2a0f55;
}
.modal-caixa h2 { font-size: 1.4rem; color: var(--cream); }
.modal-caixa .quem-e { color: var(--amber); font-weight: 700; margin: 3px 0 0; }
.modal-caixa .inspiracao {
  color: #ddcdf5; font-size: .92rem; font-style: italic; margin-top: 10px;
}
.sem-foto-grande {
  width: 100%; aspect-ratio: 3/4; max-height: 42dvh;
  display: grid; place-items: center; font-size: 4rem;
  border-radius: var(--r-md);
  background: linear-gradient(165deg, #431d80, #280f52);
}

@media (prefers-reduced-motion: reduce) {
  .destaque-aberta { animation: none; }
  .modal, .modal-caixa { transition: none; }
}

/* ================================================================ PÓDIO */

.podio { display: grid; gap: 12px; }
.podio-item {
  display: flex; align-items: center; gap: 13px;
  padding: 11px 14px;
  background: linear-gradient(100deg, rgba(96, 48, 158, .9), rgba(48, 20, 92, .92));
  border: 3px solid var(--purple-ink);
  border-radius: var(--r-md);
  box-shadow: 0 4px 0 var(--purple-ink);
}
.podio-item .pos {
  font-family: var(--font-fun); font-weight: 800; font-size: 1.5rem;
  min-width: 2ch; text-align: center;
}
.podio-item img {
  width: 56px; height: 72px; object-fit: cover; border-radius: 12px;
  border: 2px solid var(--purple-ink); background: #2a0f55; flex: none;
}
.podio-item .quem { flex: 1; min-width: 0; }
.podio-item .quem b { font-family: var(--font-fun); font-size: 1.05rem; display: block; }
.podio-item .quem small { color: var(--amber); font-weight: 600; }
.podio-item .nota { text-align: right; font-family: var(--font-fun); font-weight: 800; }
.podio-item .nota b { font-size: 1.3rem; color: var(--amber); display: block; }
.podio-item .nota small { color: #c4aee6; font-weight: 500; font-size: .74rem; }

.podio-item.p1 { border-color: var(--amber); box-shadow: 0 4px 0 #a8762a, 0 0 30px rgba(255,198,61,.3); }
.podio-item.p2 { border-color: #cfd4e0; box-shadow: 0 4px 0 #808693; }
.podio-item.p3 { border-color: #d98f52; box-shadow: 0 4px 0 #8f5324; }

/* ================================================================= AVISOS */

.aviso {
  padding: 13px 16px; border-radius: var(--r-md);
  border: 3px solid var(--purple-ink);
  background: rgba(255, 198, 61, .17);
  font-size: .95rem; margin-bottom: 16px;
}
.aviso.erro { background: rgba(255, 70, 90, .22); border-color: #8c1228; }
.aviso.ok   { background: rgba(70, 209, 127, .2); border-color: #16663c; }

.vazio-estado { text-align: center; padding: 40px 18px; color: #d4c2f0; }
.vazio-estado .big { font-size: 3.6rem; display: block; margin-bottom: 10px; }

/* =============================================================== RODAPÉ NAV */

.nav-baixo {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  display: flex; justify-content: center; gap: 6px;
  padding: 9px 10px calc(9px + env(safe-area-inset-bottom, 0px));
  background: linear-gradient(180deg, rgba(20, 6, 39, .5), rgba(20, 6, 39, .97) 45%);
  backdrop-filter: blur(10px);
  border-top: 2px solid rgba(255, 255, 255, .11);
}
.nav-baixo a {
  flex: 1; max-width: 130px;
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  padding: 7px 4px; border-radius: 16px;
  text-decoration: none; color: #b9a3dd;
  font-family: var(--font-fun); font-weight: 700; font-size: .74rem;
  transition: all .15s ease;
}
.nav-baixo a .ico { font-size: 1.3rem; line-height: 1; }
.nav-baixo a.ativo { color: var(--amber); background: rgba(255, 198, 61, .14); }

/* ================================================================= TOAST */

#toast {
  position: fixed; left: 50%; bottom: calc(86px + env(safe-area-inset-bottom, 0px));
  transform: translate(-50%, 24px);
  z-index: 100; width: min(92vw, 420px);
  padding: 13px 18px;
  border-radius: var(--r-md);
  border: 3px solid var(--purple-ink);
  background: linear-gradient(180deg, #58259c, #3a1570);
  box-shadow: 0 6px 0 var(--purple-ink), 0 16px 36px rgba(0, 0, 0, .5);
  font-family: var(--font-fun); font-weight: 700; text-align: center;
  opacity: 0; pointer-events: none;
  transition: opacity .22s ease, transform .22s cubic-bezier(.34,1.56,.64,1);
}
#toast.show { opacity: 1; transform: translate(-50%, 0); }
#toast.erro { background: linear-gradient(180deg, #b32442, #7d102c); border-color: #5e0a1e; }
#toast.ok   { background: linear-gradient(180deg, #2fa865, #1b7a47); border-color: #0d472a; }

/* =============================================================== CONFETE */

#confete { position: fixed; inset: 0; pointer-events: none; z-index: 90; }

/* ================================================================ UTILS */

.centro { text-align: center; }
.mt-8  { margin-top: 8px; }  .mt-14 { margin-top: 14px; }
.mt-20 { margin-top: 20px; } .mt-28 { margin-top: 28px; }
.mb-14 { margin-bottom: 14px; } .mb-20 { margin-bottom: 20px; }
.ajuda { font-size: .88rem; opacity: .85; line-height: 1.45; }
.pill {
  display: inline-block; padding: 4px 12px; border-radius: 999px;
  background: rgba(255, 255, 255, .12); border: 2px solid rgba(255, 255, 255, .22);
  font-size: .8rem; font-weight: 600;
}

.spinner {
  width: 22px; height: 22px; border-radius: 50%;
  border: 3px solid rgba(255, 255, 255, .25); border-top-color: var(--amber);
  animation: spin .7s linear infinite; display: inline-block;
}
@keyframes spin { to { transform: rotate(360deg); } }
