/* ============================================================================
 * FLAPYCOPA — Componentes (estilo cassino premium: vidro + ouro + neon)
 * ========================================================================== */

/* ----- Botões ---------------------------------------------------------- */
.btn { position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border-radius: var(--r-pill); font-weight: 800; line-height: 1; padding: 13px 20px; overflow: hidden;
  transition: transform .07s ease, box-shadow .15s ease, filter .15s ease; }
.btn:active { transform: translateY(3px); }
.btn::before { /* brilho de vidro no topo */ content: ''; position: absolute; inset: 1px 1px 50% 1px; border-radius: inherit;
  background: linear-gradient(180deg, rgba(255,255,255,.35), transparent); pointer-events: none; }

.btn-gold { background: var(--gold-grad); color: #3a2400; box-shadow: var(--sh-btn-gold), var(--inset-top); text-shadow: 0 1px 0 rgba(255,255,255,.5); }
.btn-gold:active { background: var(--gold-grad-press); box-shadow: var(--sh-btn-gold-press); }
.btn-green { background: var(--green-grad); color: #04300f; box-shadow: var(--sh-btn-green), var(--inset-top); text-shadow: 0 1px 0 rgba(255,255,255,.25); }
.btn-blue { background: linear-gradient(180deg, #4a97ff, #1453cf); color: #fff; box-shadow: 0 6px 0 #0e3c93, var(--inset-top), 0 12px 22px rgba(31,111,255,.35); }
.btn-red { background: var(--red-grad); color: #fff; box-shadow: 0 6px 0 #9c1515, var(--inset-top); }
.btn-ghost { background: var(--glass); -webkit-backdrop-filter: blur(var(--blur)); backdrop-filter: blur(var(--blur));
  color: var(--text); border: 1.5px solid var(--glass-border); box-shadow: var(--sh-glass); }
.btn-ghost::before { display: none; }
.btn-block { width: 100%; }
.btn-lg { padding: 16px 22px; font-size: 18px; }
.btn[disabled] { opacity: .5; pointer-events: none; filter: grayscale(.3); }

/* CTA "JOGAR" — destaque máximo */
.btn-play { position: relative; width: 88%; max-width: 360px; padding: 18px 24px; border-radius: 20px;
  display: flex; align-items: center; justify-content: space-between; overflow: hidden;
  color: #4a2c00; background: var(--gold-grad); border: 2px solid #fff0c0;
  box-shadow: var(--sh-btn-gold), var(--inset-top), inset 0 -4px 0 rgba(170,100,0,.5), var(--glow-gold);
  text-shadow: 0 2px 0 rgba(255,255,255,.5); animation: ctaPulse 2.2s ease-in-out infinite; }
.btn-play:active { transform: translateY(4px) scale(.99); box-shadow: var(--sh-btn-gold-press); animation: none; }
.btn-play::after { content: ''; position: absolute; inset: 0; background: var(--gold-sheen);
  transform: translateX(-120%); animation: sheen 3.6s ease-in-out infinite; }
.btn-play .bp-text { font-size: 27px; font-weight: 800; letter-spacing: 1px; }
.btn-play .play-tri { width: 42px; height: 42px; border-radius: 12px; background: rgba(255,255,255,.32);
  display: inline-flex; align-items: center; justify-content: center; box-shadow: inset 0 0 0 2px rgba(255,255,255,.45); flex: 0 0 auto; }
@keyframes ctaPulse { 0%,100% { box-shadow: var(--sh-btn-gold), var(--inset-top), var(--glow-gold); } 50% { box-shadow: var(--sh-btn-gold), var(--inset-top), 0 0 34px rgba(255,184,28,.9); } }
@keyframes sheen { 0% { transform: translateX(-120%); } 55%,100% { transform: translateX(120%); } }

/* ----- Pills de vidro -------------------------------------------------- */
.pill { display: inline-flex; align-items: center; gap: 8px; padding: 6px 10px 6px 7px;
  background: var(--glass); -webkit-backdrop-filter: blur(var(--blur)); backdrop-filter: blur(var(--blur));
  border: 1.5px solid var(--glass-border); border-radius: var(--r-pill); box-shadow: var(--sh-glass); }
.pill .ic { width: 28px; height: 28px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center;
  flex: 0 0 auto; font-weight: 900; font-size: 12px; }
.pill .ic.coin { background: var(--gold-grad); color: #7a4a00; box-shadow: var(--inset-top); }
.pill .ic.pix { background: linear-gradient(180deg, #3fe6ff, #0c9fc0); color: #053745; font-size: 15px; box-shadow: var(--inset-top); }
.pill .val { font-size: 14px; font-weight: 800; white-space: nowrap; font-family: var(--font-num); }
.pill.balance { padding-right: 6px; }
.pill .plus { width: 24px; height: 24px; border-radius: 50%; background: var(--green-grad); color: #04300f; font-weight: 900;
  display: inline-flex; align-items: center; justify-content: center; box-shadow: 0 2px 0 #137a28, var(--inset-top); }
.pill.click:active { transform: translateY(1px); }
.pix-pill { padding: 6px 12px 6px 7px; }

/* ----- Top bar --------------------------------------------------------- */
.topbar { position: relative; z-index: 6; display: flex; align-items: center; gap: 8px; padding: calc(10px + var(--safe-top)) 10px 8px; }
.profile-pill { display: flex; align-items: center; gap: 9px; padding: 5px 13px 5px 5px;
  background: var(--glass); -webkit-backdrop-filter: blur(var(--blur)); backdrop-filter: blur(var(--blur));
  border: 1.5px solid var(--glass-border); border-radius: var(--r-pill); box-shadow: var(--sh-glass); }
.avatar { width: 42px; height: 42px; border-radius: 50%; flex: 0 0 auto;
  background: radial-gradient(circle at 35% 30%, #ffe9a8, #f59a12); border: 2px solid #fff3c4;
  display: flex; align-items: center; justify-content: center; font-size: 22px; box-shadow: var(--glow-gold); }
.profile-meta { display: flex; flex-direction: column; gap: 4px; min-width: 88px; }
.profile-meta .pname { font-size: 12px; font-weight: 800; line-height: 1; letter-spacing: .3px; }
.xpbar { height: 9px; border-radius: 999px; background: rgba(0,0,0,.5); overflow: hidden; border: 1px solid rgba(255,255,255,.14); position: relative; }
.xpbar > i { display: block; height: 100%; background: var(--green-grad); box-shadow: var(--glow-green); width: 0; transition: width .4s ease; }
.xpbar > span { position: absolute; inset: 0; font-size: 8px; text-align: center; line-height: 9px; color: #eafff0; text-shadow: 0 1px 1px rgba(0,0,0,.7); font-family: var(--font-num); }

.icon-btn { width: 44px; height: 44px; flex: 0 0 auto; border-radius: 14px; display: flex; align-items: center; justify-content: center;
  background: var(--glass); -webkit-backdrop-filter: blur(var(--blur)); backdrop-filter: blur(var(--blur));
  border: 1.5px solid var(--glass-border); box-shadow: var(--sh-glass); }
.icon-btn:active { transform: translateY(2px); }
.icon-btn svg { width: 22px; height: 22px; }

/* ----- Botões do menu lateral ----------------------------------------- */
.side { position: absolute; top: 8px; display: flex; flex-direction: column; gap: 14px; z-index: 4; }
.side.left { left: 10px; }
.side.right { right: 10px; }
.side-btn { position: relative; width: 72px; display: flex; flex-direction: column; align-items: center; gap: 4px;
  background: linear-gradient(180deg, rgba(20,46,98,.62), rgba(8,20,48,.74)); -webkit-backdrop-filter: blur(var(--blur)); backdrop-filter: blur(var(--blur));
  border: 1.5px solid var(--glass-border); border-radius: 18px; padding: 10px 4px 7px; box-shadow: var(--sh-glass); }
.side-btn::before { content: ''; position: absolute; inset: 1px 1px 60% 1px; border-radius: 16px; background: linear-gradient(180deg, rgba(255,255,255,.16), transparent); pointer-events: none; }
.side-btn:active { transform: translateY(2px); }
.side-btn .si { width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; }
.side-btn .si svg { width: 32px; height: 32px; filter: drop-shadow(0 2px 3px rgba(0,0,0,.5)); }
.side-btn .sl { font-size: 9.5px; font-weight: 800; text-align: center; letter-spacing: .3px; color: #eaf2ff; line-height: 1.05; text-shadow: 0 1px 2px rgba(0,0,0,.6); }
.side-btn .badge { position: absolute; top: -6px; right: -4px; background: var(--red-grad); color: #fff;
  font-size: 9px; min-width: 18px; height: 18px; border-radius: 999px; padding: 0 4px; display: flex; align-items: center; justify-content: center; border: 1.5px solid #fff; box-shadow: 0 2px 6px rgba(0,0,0,.5); }

/* setas do carrossel */
.skin-arrow { position: absolute; top: 50%; transform: translateY(-50%); width: 46px; height: 46px; border-radius: 50%;
  background: var(--gold-grad); box-shadow: var(--sh-btn-gold), var(--inset-top); display: flex; align-items: center; justify-content: center;
  color: #4a2c00; z-index: 4; }
.skin-arrow:active { transform: translateY(-50%) scale(.93); }
.skin-arrow.l { left: 96px; } .skin-arrow.r { right: 96px; }
.skin-arrow svg { width: 22px; height: 22px; }

/* ----- Bottom nav ------------------------------------------------------ */
.bottomnav { position: absolute; left: 0; right: 0; bottom: 0; height: calc(var(--nav-h) + var(--safe-bottom));
  padding-bottom: var(--safe-bottom); display: flex; align-items: stretch; z-index: 8;
  background: linear-gradient(180deg, rgba(11,28,72,.86), rgba(4,12,34,.95)); -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px);
  border-top: 1.5px solid var(--glass-border); box-shadow: 0 -10px 30px rgba(0,0,0,.55); }
.nav-item { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; color: var(--text-dim); }
.nav-item svg { width: 24px; height: 24px; }
.nav-item span { font-size: 10px; font-weight: 800; letter-spacing: .3px; }
.nav-item.active { color: var(--gold-400); filter: drop-shadow(0 0 6px rgba(255,184,28,.6)); }
.nav-item.center { position: relative; }
.nav-item.center .home-fab { width: 56px; height: 56px; border-radius: 50%; margin-top: -24px;
  background: linear-gradient(180deg, #4a97ff, #1453cf); border: 3px solid #061026; color: #fff;
  display: flex; align-items: center; justify-content: center; box-shadow: 0 8px 18px rgba(31,111,255,.6), var(--inset-top); }
.nav-item.center.active .home-fab { background: var(--gold-grad); color: #4a2c00; box-shadow: 0 8px 18px rgba(255,184,28,.6), var(--inset-top); }
.nav-item:active { transform: translateY(1px); }

/* ----- Cards / listas -------------------------------------------------- */
.card { background: var(--glass-2); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  border: 1.5px solid var(--glass-border); border-radius: var(--r); padding: 14px; box-shadow: var(--sh-soft); }
.list-item { display: flex; align-items: center; gap: 12px; padding: 12px; background: rgba(255,255,255,.05);
  border: 1px solid var(--glass-border); border-radius: var(--r-sm); }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: var(--r-pill);
  background: rgba(255,255,255,.07); border: 1.5px solid var(--glass-border); font-weight: 800; font-size: 14px; }
.chip.sel { background: var(--gold-grad); color: #3a2400; border-color: #ffe9a8; box-shadow: var(--inset-top); }
.chip:active { transform: translateY(1px); }

/* ----- Modais ---------------------------------------------------------- */
#modal-root { position: absolute; inset: 0; z-index: 20; display: none; }
#modal-root.open { display: block; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(2,6,15,.7); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); animation: pop .15s ease; }
.sheet { position: absolute; left: 0; right: 0; bottom: 0; max-height: 92%; display: flex; flex-direction: column;
  background: var(--panel); -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px);
  border-top-left-radius: 28px; border-top-right-radius: 28px; border: 1.5px solid var(--glass-border); border-bottom: 0;
  box-shadow: 0 -18px 44px rgba(0,0,0,.66); animation: sheetUp .24s cubic-bezier(.2,.8,.2,1); padding-bottom: var(--safe-bottom); }
@keyframes sheetUp { from { transform: translateY(100%); } to { transform: translateY(0); } }
.sheet .grabber { width: 44px; height: 5px; border-radius: 999px; background: rgba(255,255,255,.28); margin: 10px auto 4px; }
.sheet-head { display: flex; align-items: center; gap: 10px; padding: 6px 16px 12px; }
.sheet-head .ttl { font-size: 19px; font-weight: 800; }
.sheet-head .x { margin-left: auto; width: 34px; height: 34px; border-radius: 50%; background: rgba(255,255,255,.1);
  display: flex; align-items: center; justify-content: center; font-size: 18px; border: 1px solid var(--glass-border); }
.sheet-body { padding: 4px 16px 18px; overflow-y: auto; }
.sheet-body::-webkit-scrollbar { display: none; }

/* ----- Toasts ---------------------------------------------------------- */
#toast-root { position: absolute; top: calc(74px + var(--safe-top)); left: 0; right: 0; z-index: 40; display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none; }
.toast { background: rgba(6,16,38,.96); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  border: 1.5px solid var(--glass-border); border-radius: var(--r-pill); padding: 11px 18px; font-size: 13px; font-weight: 800;
  box-shadow: var(--sh-soft); animation: pop .18s ease; max-width: 90%; }
.toast.good { border-color: var(--green-500); color: #d9ffe2; }
.toast.bad { border-color: var(--red-500); color: #ffdada; }
.toast.gold { border-color: var(--gold-500); color: #fff0c2; }

/* ----- Selo DEMO ------------------------------------------------------- */
.demo-badge { position: absolute; top: calc(64px + var(--safe-top)); left: 50%; transform: translateX(-50%);
  background: repeating-linear-gradient(45deg, #ffb81c 0 10px, #1a1a1a 10px 20px); color: #fff;
  font-size: 10px; font-weight: 900; letter-spacing: 2px; padding: 4px 14px; border-radius: 999px;
  z-index: 9; text-shadow: 0 1px 2px #000; box-shadow: var(--sh-soft); }

/* cadastro / login */
.auth-head { font-size: 14px; color: var(--text-dim); margin-bottom: 12px; }
.auth-sec { font-size: 11px; font-weight: 900; color: var(--gold-400); text-transform: uppercase; letter-spacing: 1.2px; margin: 14px 0 8px; padding-top: 10px; border-top: 1px solid var(--glass-border); }
select.field { -webkit-appearance: none; appearance: none; }
.vol-slider { -webkit-appearance: none; appearance: none; width: 130px; height: 6px; border-radius: 999px; background: rgba(0,0,0,.45); outline: none; }
.vol-slider::-webkit-slider-thumb { -webkit-appearance: none; width: 18px; height: 18px; border-radius: 50%; background: var(--gold-grad); box-shadow: var(--inset-top), 0 1px 3px rgba(0,0,0,.5); cursor: pointer; }
.vol-slider::-moz-range-thumb { width: 18px; height: 18px; border: 0; border-radius: 50%; background: #ffb81c; cursor: pointer; }

/* termos / regras */
.terms h4 { font-size: 13px; font-weight: 800; color: var(--gold-300); margin: 10px 0 4px; }
.terms h4:first-child { margin-top: 0; }
.terms p { font-size: 12.5px; line-height: 1.55; color: var(--text-dim); margin: 0 0 4px; }
.terms b { color: #dce8ff; }

/* inputs */
.field { width: 100%; padding: 14px 16px; border-radius: var(--r-sm); background: rgba(0,0,0,.35);
  border: 1.5px solid var(--glass-border); color: #fff; font-weight: 800; font-size: 16px; outline: none; }
.field:focus { border-color: var(--gold-500); box-shadow: 0 0 0 3px rgba(255,184,28,.18); }
.label { font-size: 12px; color: var(--text-dim); font-weight: 800; margin: 2px 0 6px; }
