/* ============================================================================
   Cartomante FC — App 2026 · sapo.css
   Boca do Sapo (/sapo/) — zoeira entre cartoleiros com créditos Cartomante.
   Design FIXO dark (família da Caixa de Runas), com tinta verde-pântano.
   Placeholder visual: sapo em emoji 🐸 (artes IA ficam pra depois da validação).
   ============================================================================ */

.sp-page {
  max-width: 640px;
  margin: 0 auto;
  padding: 16px 16px 48px;
  color: #E2E8F0;
  font-family: 'Inter', system-ui, sans-serif;
}

.sp-head { text-align: center; margin: 8px 0 14px; }
.sp-head h1 {
  font-size: 26px; font-weight: 900; letter-spacing: .5px; margin: 0 0 6px;
  background: linear-gradient(180deg, #86EFAC, #16A34A);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.sp-head p { margin: 0; font-size: 13.5px; color: #94A3B8; line-height: 1.45; }

/* ── A boca (cena: arte do sapo + overlays de escudo e placa) ──
   Coordenadas em % medidas na arte sapo.webp (1254×1254):
   boca (cavidade escura) centro ≈ 49.6% × 36.5% · placa útil ≈ 27..73% × 59.5..82.5% */
.sp-boca {
  background: #0B1022;
  border: 1px solid rgba(34,197,94,.35);
  border-radius: 16px; overflow: hidden;
  box-shadow: 0 10px 40px rgba(0,0,0,.5);
}
.sp-cena { position: relative; }
.sp-sapo-img { display: block; width: 100%; height: auto; user-select: none; -webkit-user-select: none; }
/* quadro da boca FECHADA (mastigação por troca de quadros — o JS alterna .mastiga) */
.sp-sapo-img--fechado {
  position: absolute; inset: 0; opacity: 0; pointer-events: none;
  transition: opacity .1s linear;
}
.sp-cena.mastiga .sp-sapo-img--fechado { opacity: 1; }
/* escudo do time engolido, DENTRO da boca (some com squish quando a boca fecha) */
.sp-escudo {
  position: absolute; left: 49.6%; top: 36.5%;
  width: 19%; transform: translate(-50%, -50%);
  filter: drop-shadow(0 0 16px rgba(251,191,36,.55)) drop-shadow(0 4px 8px rgba(0,0,0,.7));
  transition: opacity .16s ease, transform .16s ease;
}
.sp-cena.mastiga .sp-escudo { opacity: 0; transform: translate(-50%, -50%) scale(.55); }
/* conteúdo escrito da PLACA de madeira (overlay HTML — a arte é em branco) */
.sp-signo {
  position: absolute; left: 27%; top: 59.5%;
  width: 46%; height: 23%;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 1%;
  text-align: center; overflow: hidden; padding: 0 1%;
}
/* letreiro "pintado a ouro" na madeira: claro + sombra escura forte (contraste) */
.sp-signo__tag {
  font-size: clamp(11px, 2.6vw, 17px); font-weight: 900; letter-spacing: 2px;
  color: #FDE68A; text-shadow: 0 1px 3px rgba(15,8,2,.95), 0 0 6px rgba(0,0,0,.6);
}
.sp-signo__nome {
  font-size: clamp(13px, 3.4vw, 22px); font-weight: 900; line-height: 1.15;
  color: #FFF3D6;
  text-shadow: 0 2px 5px rgba(15,8,2,.95), 0 0 10px rgba(0,0,0,.65), 0 0 2px rgba(0,0,0,.9);
  max-width: 100%; overflow: hidden;
}
.sp-signo__cart {
  font-size: clamp(12px, 2.9vw, 18px); font-weight: 800;
  color: #F3DFAE; text-shadow: 0 1px 3px rgba(15,8,2,.95), 0 0 6px rgba(0,0,0,.6);
  max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.sp-meta { text-align: center; font-size: 11.5px; color: #64748B; padding: 8px 12px 4px; }
.sp-meta b { color: #FDE68A; }
.sp-share-row { text-align: center; margin: 0; padding: 4px 12px 12px; }
.sp-share {
  background: none; border: 1px solid rgba(251,191,36,.4); border-radius: 10px;
  color: #FDE68A; padding: 7px 14px; font-size: 12px; font-weight: 700;
  font-family: inherit; cursor: pointer;
}
.sp-share:active { background: rgba(251,191,36,.12); }

/* ── Bolada ── */
.sp-bolada {
  display: flex; gap: 10px; margin-top: 14px;
}
.sp-bolada__box {
  flex: 1; text-align: center;
  background: #111936; border: 1px solid rgba(77,82,175,.3);
  border-radius: 14px; padding: 12px 8px;
}
.sp-bolada__box b { display: block; font-size: 20px; font-weight: 900; color: #FDE68A; }
.sp-bolada__box span { font-size: 10.5px; color: #94A3B8; letter-spacing: .3px; text-transform: uppercase; }
.sp-bolada__box.destaque { border-color: rgba(34,197,94,.45); }
.sp-bolada__box.destaque b { color: #86EFAC; }

/* CTA dentro do card do prêmio (concorrer à bolada) — texto SEMPRE branco no laranja */
.sp-cta {
  display: block; width: 100%; margin-top: 9px;
  background: linear-gradient(180deg, #F5921A, #D97706);
  color: #fff; border: 0; border-radius: 10px;
  padding: 8px 6px; font-size: 12px; font-weight: 800;
  font-family: inherit; cursor: pointer; white-space: nowrap;
}
.sp-cta:active { filter: brightness(.9); }

/* card-botão "Engolir outro time" — cara de BOTÃO de verdade (abre o popup) */
.sp-bolada__acao {
  cursor: pointer; font-family: inherit;
  background: linear-gradient(180deg, #22C55E, #15803D);
  border: 0;
  box-shadow: 0 6px 20px rgba(34,197,94,.35), inset 0 1px 0 rgba(255,255,255,.25);
  transition: transform .12s ease, filter .12s ease;
}
.sp-bolada__acao b { color: #fff; font-size: 15px; line-height: 1.25; text-shadow: 0 1px 2px rgba(0,0,0,.35); }
.sp-bolada__acao span { color: rgba(255,255,255,.85); }
.sp-bolada__acao:hover { transform: translateY(-2px); filter: brightness(1.07); }
.sp-bolada__acao:active { transform: translateY(0); filter: brightness(.92); }

@media (max-width: 480px) {
  .sp-bolada { flex-direction: column; }
  .sp-bolada__box b { font-size: 18px; }
}

/* ── Popup "Engolir outro time" ── */
.sp-modal-ov {
  position: fixed; inset: 0; z-index: 120;
  background: rgba(4, 7, 18, .78); backdrop-filter: blur(3px);
  display: flex; align-items: center; justify-content: center; padding: 16px;
}
.sp-modal {
  width: min(94vw, 420px); max-height: 88vh; overflow-y: auto;
  background: linear-gradient(180deg, #131A33, #0F172A);
  border: 1px solid rgba(34,197,94,.45); border-radius: 16px;
  padding: 16px; color: #E2E8F0; font-family: 'Inter', system-ui, sans-serif;
  box-shadow: 0 18px 60px rgba(0,0,0,.7);
}
.sp-modal__hd { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.sp-modal__hd b { font-size: 15px; color: #86EFAC; }
.sp-modal__x { background: none; border: 0; color: #94A3B8; font-size: 24px; line-height: 1; cursor: pointer; padding: 0 4px; }

/* abas do popup (Time / Jogador / Clube) */
.sp-tabs { display: flex; gap: 6px; margin-bottom: 10px; }
.sp-tab {
  flex: 1; background: #0B1022; border: 1px solid rgba(77,82,175,.5); border-radius: 10px;
  color: #94A3B8; padding: 8px 4px; font-size: 12.5px; font-weight: 800;
  font-family: inherit; cursor: pointer;
}
.sp-tab.on {
  background: linear-gradient(180deg, rgba(34,197,94,.25), #0F172A);
  border-color: rgba(34,197,94,.6); color: #86EFAC;
}

/* grade de clubes (aba Clube) */
.sp-clubes { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.sp-clubes .sp-busca__vazio { grid-column: 1 / -1; }
.sp-clube {
  background: #1B2342; border: 1px solid rgba(77,82,175,.4); border-radius: 10px;
  color: #CBD5E1; padding: 8px 4px; font-family: inherit; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  font-size: 10.5px; line-height: 1.15; text-align: center;
}
.sp-clube img { width: 34px; height: 34px; object-fit: contain; }
.sp-clube:active { background: #2D2E6E; }

/* foto de jogador é redonda (busca, seleção e boca) */
.sp-busca__item--jog img, .sp-sel--jog img { border-radius: 50%; background: #0B1022; object-fit: cover; }
.sp-escudo--jogador {
  border-radius: 50%; aspect-ratio: 1; object-fit: cover;
  background: radial-gradient(circle, #1B2342, #0B1022);
  border: 2px solid rgba(251,191,36,.55);
}
.sp-saldo { text-align: center; font-size: 13px; color: #94A3B8; margin-bottom: 12px; }
.sp-saldo b { color: #FDE68A; font-size: 15px; }
.sp-saldo .sp-login-link { color: #F5921A; font-weight: 700; cursor: pointer; text-decoration: underline; }

.sp-lbl { font-size: 11px; font-weight: 800; color: #A5B4FC; letter-spacing: .5px; text-transform: uppercase; margin: 0 0 8px; }
.sp-busca { position: relative; }
.sp-busca input {
  width: 100%; box-sizing: border-box;
  background: #0B1022; border: 1px solid rgba(77,82,175,.5); border-radius: 12px;
  color: #E2E8F0; padding: 11px 13px; font-size: 14px; font-family: inherit;
}
.sp-busca__res { margin-top: 6px; }
.sp-busca__item {
  display: flex; align-items: center; gap: 10px; width: 100%; box-sizing: border-box;
  background: #1B2342; border: 1px solid rgba(77,82,175,.4); border-radius: 12px;
  color: #E2E8F0; padding: 8px 10px; margin-bottom: 6px;
  font-family: inherit; cursor: pointer; text-align: left; font-size: 13px;
}
.sp-busca__item:active { background: #2D2E6E; }
.sp-busca__item img { width: 34px; height: 34px; object-fit: contain; }
.sp-busca__item small { display: block; color: #94A3B8; font-size: 11.5px; }
.sp-busca__vazio { color: #64748B; font-size: 12.5px; padding: 6px 2px; }

.sp-sel {
  display: flex; align-items: center; gap: 10px;
  background: #10241C; border: 1px solid rgba(34,197,94,.45); border-radius: 12px;
  padding: 10px 12px; margin-top: 10px; font-size: 13.5px;
}
.sp-sel img { width: 40px; height: 40px; object-fit: contain; }
.sp-sel small { display: block; color: #94A3B8; font-size: 11.5px; }
.sp-sel .sp-sel__x { margin-left: auto; background: none; border: 0; color: #94A3B8; font-size: 20px; cursor: pointer; }

.sp-btn {
  display: block; width: 100%; margin-top: 12px;
  background: linear-gradient(180deg, #22C55E, #15803D);
  color: #fff; border: 0; border-radius: 14px;
  padding: 14px 10px; font-size: 15px; font-weight: 900; letter-spacing: .3px;
  cursor: pointer; font-family: inherit;
  box-shadow: 0 6px 20px rgba(34,197,94,.3);
}
.sp-btn--laranja {
  background: linear-gradient(180deg, #F5921A, #D97706);   /* texto SEMPRE branco */
  box-shadow: 0 6px 20px rgba(245,146,26,.3);
}
.sp-btn:disabled { opacity: .45; cursor: default; box-shadow: none; }
.sp-hint { text-align: center; font-size: 11.5px; color: #64748B; margin-top: 10px; line-height: 1.5; }

/* ── Feed / listas ── */
.sp-listas { margin-top: 16px; display: grid; gap: 14px; }
.sp-card { background: #111936; border: 1px solid rgba(77,82,175,.3); border-radius: 14px; padding: 14px; }
.sp-card h2 { margin: 0 0 10px; font-size: 13px; font-weight: 800; color: #A5B4FC; letter-spacing: .5px; text-transform: uppercase; }
.sp-card ul { list-style: none; margin: 0; padding: 0; }
.sp-card li {
  display: flex; justify-content: space-between; gap: 10px;
  font-size: 13px; color: #CBD5E1; padding: 6px 0;
  border-bottom: 1px dashed rgba(100,116,139,.25);
}
.sp-card li:last-child { border-bottom: 0; }
.sp-card li b { color: #fff; }
.sp-card li .cc { color: #FDE68A; font-weight: 800; }
.sp-card li time { color: #64748B; font-size: 12px; white-space: nowrap; }
.sp-vazio { color: #64748B; font-size: 12.5px; }
.sp-sorteio {
  background: linear-gradient(90deg, rgba(34,197,94,.12), rgba(251,191,36,.12));
  border: 1px solid rgba(251,191,36,.35); border-radius: 12px;
  padding: 10px 12px; font-size: 13px; color: #FDE68A; margin-bottom: 10px;
}

/* regras resumidas */
.sp-regras { font-size: 12px; color: #64748B; line-height: 1.6; }
.sp-regras b { color: #94A3B8; }

/* engolir: animação simples do sapo (bounce + escala) */
.sp-sapo-img.gulp { animation: spGulp .9s ease; transform-origin: 50% 60%; }
@keyframes spGulp {
  0% { transform: scale(1); }
  30% { transform: scale(1.25) translateY(6px); }
  55% { transform: scale(.92); }
  100% { transform: scale(1); }
}

/* ── Toast ── */
.sp-toast {
  position: fixed; left: 50%; bottom: 26px;
  transform: translate(-50%, 20px);
  background: #1B2342; color: #E2E8F0;
  border: 1px solid rgba(34,197,94,.5);
  border-radius: 12px; padding: 12px 16px;
  font-size: 13.5px; font-family: 'Inter', system-ui, sans-serif;
  box-shadow: 0 10px 30px rgba(0,0,0,.6);
  opacity: 0; pointer-events: none;
  transition: opacity .3s, transform .3s;
  z-index: 90; max-width: min(92vw, 420px); text-align: center;
}
.sp-toast.on { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 480px) {
  .sp-page { padding: 12px 10px 40px; }
  .sp-head h1 { font-size: 22px; }
  .sp-frog { font-size: 80px; }
}
