/* ============================================================
   BOLÃO DA COPA — UI KIT  (folha de estilo principal)
   ------------------------------------------------------------
   Mexa nas variáveis abaixo para mudar TODO o visual.
   Organização:
     1. Tokens (cores, fontes, espaços, raios)
     2. Base / reset
     3. Layout (app, header, footer, bottom-nav, página)
     4. Blocos (cards, listas, badges)
     5. Inputs e formulários
     6. Botões
     7. Componentes de bolão (jogo, placar, ranking)
     8. Utilitários e animações
   ============================================================ */

/* ============ 1. TOKENS ============ */
:root {
  color-scheme: light;
  /* ---- TEMA CLARO (lima neon + charcoal + branco) — padrão ---- */
  --bg:        #f5f6f2;
  --bg-2:      #ffffff;
  --surface:   #ffffff;
  --surface-2: #ececdf;
  --ink:       #181a12;   /* charcoal — cards de destaque */
  --ink-2:     #23261c;
  --line:      rgba(20, 24, 10, 0.10);
  --line-soft: rgba(20, 24, 10, 0.055);

  --brand:      #c6ff3d;  /* lima neon — preenchimentos */
  --brand-strong:#b6f200;
  --brand-ink:  #16180c;  /* texto sobre a lima */
  --brand-text: #3f8c12;  /* verde legível p/ texto em fundo claro */
  --lime:       #c6ff3d;
  --gold:       #e9b200;
  --live:       #ff5a4d;
  --blue:       #4f7cff;

  --text:      #17180f;
  --muted:     #6f7368;
  --faint:     #a4a89c;

  --header-bg: rgba(238,240,234,.85);
  --nav-bg:    rgba(255,255,255,.72);

  /* Tipografia */
  --font-display: "Archivo", system-ui, sans-serif;
  --font:         "Archivo", system-ui, -apple-system, sans-serif;

  /* Espaçamento */
  --sp-1: 4px;  --sp-2: 8px;  --sp-3: 12px; --sp-4: 16px;
  --sp-5: 24px; --sp-6: 32px; --sp-7: 48px;

  /* Raios e sombras */
  --r-sm: 14px; --r:  22px; --r-lg: 30px; --r-pill: 999px;
  --shadow:    0 14px 32px -18px rgba(20,30,10,.26);
  --shadow-lg: 0 28px 64px -24px rgba(20,30,10,.30);
  --glow:      0 0 0 1px rgba(182,242,0,.5), 0 12px 30px -10px rgba(182,242,0,.5);

  --app-max: 393px;       /* largura lógica do iPhone 15 Pro (393 × 852) */
  --header-h: 62px;
  --nav-h: 90px;
}

/* ---- TEMA ESCURO (charcoal + lima) — via toggle ---- */
[data-theme="dark"] {
  color-scheme: dark;
  --bg:        #0d0f0b;
  --bg-2:      #15170f;
  --surface:   #1a1c14;
  --surface-2: #24271c;
  --ink:       #000000;
  --ink-2:     #101109;
  --line:      rgba(220, 255, 180, 0.10);
  --line-soft: rgba(220, 255, 180, 0.06);

  --brand:      #c6ff3d;
  --brand-strong:#b6f200;
  --brand-ink:  #16180c;
  --brand-text: #c6ff3d;
  --lime:       #c6ff3d;
  --gold:       #ffd23f;
  --live:       #ff5a4d;
  --blue:       #6f97ff;

  --text:      #eef3e6;
  --muted:     #9aa091;
  --faint:     #646b58;

  --header-bg: rgba(13,15,11,.8);
  --nav-bg:    rgba(20,23,16,.72);

  --shadow:    0 16px 36px -18px rgba(0,0,0,.7);
  --shadow-lg: 0 28px 64px -24px rgba(0,0,0,.8);
  --glow:      0 0 0 1px rgba(198,255,61,.4), 0 10px 30px -8px rgba(198,255,61,.45);
}

/* ---- Material Symbols (Google Icons) ---- */
.msym {
  font-family: "Material Symbols Outlined";
  font-weight: normal; font-style: normal; line-height: 1;
  letter-spacing: normal; text-transform: none; white-space: nowrap;
  word-wrap: normal; direction: ltr; display: inline-block;
  -webkit-font-feature-settings: "liga"; font-feature-settings: "liga";
  -webkit-font-smoothing: antialiased; vertical-align: middle;
  font-variation-settings: "FILL" 0, "wght" 500, "GRAD" 0, "opsz" 24;
}
.msym.fill { font-variation-settings: "FILL" 1, "wght" 500, "GRAD" 0, "opsz" 24; }
.ico-inline { font-size: 1.05em; margin-right: 4px; vertical-align: -3px; }

/* ============ 2. BASE ============ */
* { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  font-size: 16.5px;
  background-image:
    radial-gradient(1100px 560px at 50% -12%, color-mix(in srgb, var(--brand) 22%, transparent), transparent 58%);
  background-attachment: fixed;
  line-height: 1.5;
  min-height: 100vh;
  min-height: 100dvh;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font-family: inherit; }
::selection { background: var(--brand); color: var(--brand-ink); }

h1,h2,h3 { line-height: 1.04; font-weight: 800; letter-spacing: -.4px; }
.display { font-family: var(--font-display); font-weight: 800; letter-spacing: -.4px; }

/* ============ 3. LAYOUT ============ */
.app {
  width: 100%;
  max-width: var(--app-max);
  margin: 0 auto;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  position: relative;
  background: transparent;
  box-shadow: 0 0 80px -30px rgba(0,0,0,.25);
}

/* HEADER */
.app-header {
  position: sticky; top: 0; z-index: 40;
  height: var(--header-h);
  display: flex; align-items: center; gap: var(--sp-3);
  padding: 0 var(--sp-4);
  background: var(--header-bg);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.app-header .logo {
  display: flex; align-items: center; gap: 9px;
  font-family: var(--font-display); font-size: 21px; font-weight: 800;
  letter-spacing: -.5px;
}
.app-header .logo .ball {
  width: 28px; height: 28px; border-radius: 50%;
  background: radial-gradient(circle at 32% 30%, #fff 0 22%, transparent 23%),
              conic-gradient(from 20deg, var(--brand), var(--lime), var(--brand));
  box-shadow: var(--glow); flex: none;
  animation: spin 9s linear infinite;
}
.app-header .logo b { color: var(--brand-text); }
.app-header .spacer { flex: 1; }
.app-header .me {
  display: flex; align-items: center; gap: 8px;
  font-size: 13px; color: var(--muted);
}
.icon-btn {
  display: grid; place-items: center; width: 38px; height: 38px; flex: none;
  border-radius: 50%; border: 1px solid var(--line); background: var(--surface-2);
  color: var(--muted); cursor: pointer; transition: color .2s, border-color .2s, transform .12s;
}
.icon-btn:hover { color: var(--brand); border-color: var(--brand); }
.icon-btn:active { transform: scale(.92); }
.icon-btn .msym { font-size: 20px; }
.bolao-pick { display: flex; align-items: center; gap: 7px; max-width: 56%; padding: 6px 10px 6px 7px; border-radius: var(--r-pill); background: var(--surface-2); border: 1px solid var(--line); color: var(--text); font-weight: 700; font-size: 14px; }
.bolao-pick img { width: 24px; height: 24px; border-radius: 50%; object-fit: cover; flex: none; }
.bolao-pick .msym { font-size: 19px; color: var(--brand-text); flex: none; }
.bolao-pick .bn { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dot-badge { position: absolute; top: 4px; right: 4px; width: 9px; height: 9px; border-radius: 50%; background: var(--live); border: 2px solid var(--surface); }

/* card de perfil com capa */
.profile-cover { position: relative; border-radius: var(--r); overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow); }
.profile-cover .pc-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; }
.profile-cover .pc-ov { position: absolute; inset: 0; z-index: 1; background: linear-gradient(180deg, rgba(20,24,12,.45), rgba(20,24,12,.82)); }
.profile-cover .pc-inner { position: relative; z-index: 2; padding: 22px 18px; display: flex; align-items: center; gap: 14px; color: #fff; }
.profile-cover .pc-inner .nm { font-family: var(--font-display); font-size: 22px; font-weight: 800; line-height: 1.1; }
.profile-cover .pc-inner .sub { font-size: 12.5px; color: rgba(255,255,255,.9); display: flex; align-items: center; gap: 5px; margin-top: 2px; }
.profile-cover .avatar, .hero-cover .avatar { background: radial-gradient(circle at 50% 30%, #e6ff90, var(--brand) 78%); border-color: #fff; box-shadow: 0 4px 14px rgba(0,0,0,.35); }
.profile-cover .avatar .msym, .hero-cover .avatar .msym { color: #16180c; }
/* badge legível sobre capa/escuro: lima sólido + texto escuro */
.profile-cover .badge, .hero-cover .badge { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); font-weight: 800; }
.profile-cover .pc-edit { position: absolute; top: 12px; right: 12px; z-index: 3; }
/* card do bolão na home: mais alto + faixa da posição do participante */
.bolao-home .pc-inner { flex-direction: column; align-items: stretch; gap: 14px; padding: 20px 18px; }
.bolao-home .pc-top { display: flex; align-items: center; gap: 14px; }
.bolao-home .pc-you {
  display: flex; align-items: center; gap: 12px; padding-top: 14px;
  border-top: 1px solid rgba(255,255,255,.18);
}
.bolao-home .pc-you .you-score { margin-left: auto; text-align: right; }
.bolao-home .pc-you .you-score .n { font-family: var(--font-display); font-size: 32px; font-weight: 800; color: var(--brand); line-height: .9; }
.bolao-home .pc-you .you-score .u { font-size: 10px; color: rgba(255,255,255,.7); text-transform: uppercase; letter-spacing: .5px; }
.bolao-home .pc-you .you-pos { display: flex; align-items: center; gap: 6px; font-weight: 800; font-size: 15px; }

/* PÁGINA */
.page {
  flex: 1;
  padding: var(--sp-4) var(--sp-4) calc(var(--nav-h) + 28px);
  animation: fadeUp .45s ease both;
}
.page-title {
  font-family: var(--font-display);
  font-size: clamp(32px, 9.5vw, 46px); font-weight: 800;
  letter-spacing: -1.5px;
  line-height: 1.0; margin-bottom: 2px;
}
.page-sub { color: var(--muted); font-size: 15.5px; margin-bottom: var(--sp-5); }
.page-head { text-align: center; margin-bottom: var(--sp-5); }
.page-head .eyebrow { justify-content: center; }
.page-head .page-title { margin-bottom: 4px; }
.page-head .page-sub { margin: 0 auto; max-width: 36ch; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; font-weight: 700; letter-spacing: 1.5px;
  text-transform: uppercase; color: var(--brand-text);
  margin-bottom: var(--sp-2);
}
.section-head {
  display: flex; align-items: baseline; justify-content: space-between;
  margin: var(--sp-6) 0 var(--sp-3);
}
.section-head h2 { font-family: var(--font-display); font-size: 25px; font-weight: 800; letter-spacing: -.6px; }
.section-head .link { color: var(--brand-text); font-size: 14px; font-weight: 700; }

/* FOOTER */
.app-footer {
  text-align: center; padding: var(--sp-5) var(--sp-4) var(--sp-4);
  border-top: 1px solid var(--line-soft);
  color: var(--faint); font-size: 13px; line-height: 1.7;
}
.app-footer b { color: var(--muted); }
.app-footer a { color: var(--brand-text); }
.app-footer .footer-logo { height: 30px; width: auto; margin-top: 10px; display: inline-block; vertical-align: middle; transition: opacity .15s; }
.app-footer .footer-logo:hover { opacity: .8; }

/* BOTTOM NAV (pílula flutuante com botões circulares) */
.bottom-nav {
  position: fixed; bottom: 16px; left: 50%; transform: translateX(-50%);
  width: calc(100% - 32px); max-width: min(480px, calc(var(--app-max) - 32px)); z-index: 50;
  height: 66px;
  display: grid; grid-auto-flow: column; grid-auto-columns: 1fr;
  align-items: center; justify-items: center;
  background: var(--nav-bg);
  backdrop-filter: blur(18px);
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  box-shadow: var(--shadow-lg);
  padding: 0 8px;
}
.bottom-nav a {
  width: 50px; height: 50px; border-radius: 50%;
  display: grid; place-items: center;
  color: var(--muted); transition: background .2s, color .2s, transform .12s;
}
.bottom-nav a span:not(.msym) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.bottom-nav a .msym { font-size: 26px; }
.bottom-nav a.active {
  background: var(--brand); color: var(--brand-ink);
  box-shadow: 0 8px 18px -6px rgba(182,242,0,.75);
}
.bottom-nav a:active { transform: scale(.9); }

/* ============ 4. BLOCOS ============ */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: var(--sp-4);
  box-shadow: var(--shadow);
}
/* card-dark / hero com capa de fundo */
.hero-cover { position: relative; overflow: hidden; border-radius: var(--r-lg); border: 1px solid rgba(255,255,255,.08); box-shadow: var(--shadow); color: #f3f7ec; }
.hero-cover .hc-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; }
.hero-cover .hc-ov { position: absolute; inset: 0; z-index: 1; background: linear-gradient(150deg, rgba(16,18,9,.72), rgba(16,18,9,.86)); }
.hero-cover .hc-inner { position: relative; z-index: 2; padding: var(--sp-5); }
.hero-cover .lime { color: var(--brand); }
.hero-cover .muted { color: rgba(243,247,236,.7); }
.card.glow { box-shadow: var(--glow); border-color: rgba(182,242,0,.45); }
.card-grad {
  position: relative; overflow: hidden;
  background:
    linear-gradient(135deg, rgba(182,242,0,.16), transparent 70%),
    var(--surface);
  border: 1px solid rgba(182,242,0,.30);
}
/* card charcoal (destaque, números em lima) */
.card-dark {
  background: var(--ink); color: #f3f7ec;
  border: 1px solid rgba(255,255,255,.07); border-radius: var(--r-lg);
  padding: var(--sp-5); box-shadow: var(--shadow);
}
.card-dark .lime, .card-dark .accent { color: var(--brand); }
.card-dark .muted { color: rgba(243,247,236,.55); }
.card-dark .badge { background: rgba(255,255,255,.10); color: #f3f7ec; border-color: rgba(255,255,255,.14); }
.card-dark .badge.brand { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.stack > * + * { margin-top: var(--sp-3); }
.row { display: flex; align-items: center; gap: var(--sp-3); }
.row.between { justify-content: space-between; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-3); }

/* BADGES / CHIPS */
.badge {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 11px; border-radius: var(--r-pill);
  font-size: 12.5px; font-weight: 700; letter-spacing: .3px;
  background: var(--surface-2); color: var(--muted);
  border: 1px solid var(--line);
}
.badge.brand { background: rgba(182,242,0,.18); color: var(--brand-text); border-color: rgba(182,242,0,.40); }
.badge.gold  { background: rgba(233,178,0,.16); color: #9a7400;  border-color: rgba(233,178,0,.34); }
.badge.live  { background: rgba(255,90,77,.16);  color: var(--live);  border-color: rgba(255,90,77,.35); }
.badge.live .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--live); animation: pulse 1.2s infinite; }
/* selos de modo (cada um uma cor) */
.badge.m-cravador   { background: rgba(182,242,0,.22); color: var(--brand-text); border-color: rgba(182,242,0,.42); }
.badge.m-alta       { background: rgba(79,124,237,.16); color: #2f5fd0; border-color: rgba(79,124,237,.36); }
.badge.m-palpiteiro { background: rgba(233,178,0,.18); color: #9a7400; border-color: rgba(233,178,0,.34); }
.badge.m-espectador { background: var(--surface-2); color: var(--muted); border-color: var(--line); }
[data-theme="dark"] .badge.m-alta { color: #9db8ff; }
[data-theme="dark"] .badge.m-palpiteiro { color: #ffd23f; }

/* AVATAR */
.avatar {
  width: 44px; height: 44px; border-radius: 50%; flex: none;
  display: grid; place-items: center; font-size: 20px;
  background: radial-gradient(circle at 50% 28%, #e6ff90, var(--brand) 78%);
  border: 2px solid var(--brand);
  overflow: hidden; position: relative;
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar.lg { width: 72px; height: 72px; font-size: 32px; }
.avatar.xl { width: 96px; height: 96px; font-size: 44px; }
.avatar.ring { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(182,242,0,.22); }
.avatar .msym { font-size: 24px; color: var(--brand-ink); }
.avatar.lg .msym { font-size: 34px; }
.avatar.xl .msym { font-size: 46px; }

/* ============ 5. INPUTS ============ */
.field { margin-bottom: var(--sp-4); }
.label {
  display: block; font-size: 13px; font-weight: 700; letter-spacing: .4px;
  text-transform: uppercase; color: var(--muted); margin-bottom: 6px;
}
.input, .select, .textarea {
  width: 100%; padding: 14px 14px;
  background: var(--bg-2); color: var(--text);
  border: 1.5px solid var(--line); border-radius: var(--r-sm);
  font-size: 16px; transition: border-color .2s, box-shadow .2s, background .2s;
}
.input::placeholder { color: var(--faint); }
.input:focus, .select:focus, .textarea:focus {
  outline: none; border-color: var(--brand-strong);
  box-shadow: 0 0 0 4px rgba(182,242,0,.20); background: var(--bg);
}
.input-icon { position: relative; }
.input-icon .input { padding-left: 44px; }
.input-icon svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--faint); }
.input-icon .msym { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); color: var(--faint); font-size: 20px; pointer-events: none; }

/* INPUT com LABEL FLUTUANTE (moderno) */
.fl { position: relative; }
.fl .input {
  height: 62px; padding: 28px 16px 8px; font-size: 16.5px; font-weight: 600;
  border-width: 2px; border-radius: 16px;
}
.fl label {
  position: absolute; left: 16px; top: 50%; transform: translateY(-50%);
  color: var(--faint); font-size: 16px; font-weight: 500; pointer-events: none;
  transform-origin: left center;
  transition: transform .16s ease, color .16s ease;
}
.fl .input:focus ~ label,
.fl .input:not(:placeholder-shown) ~ label {
  transform: translateY(-22px) scale(.76); font-weight: 800;
  letter-spacing: .4px; text-transform: uppercase; color: var(--brand-text);
}
.fl .input:focus ~ label { color: var(--brand-text); }

/* ===== TELAS DE AUTENTICAÇÃO (hero gradiente + folha) ===== */
.auth { width: 100%; max-width: var(--app-max); margin: 0 auto; min-height: 100dvh; display: flex; flex-direction: column; background: var(--ink); }
.auth-hero {
  position: relative; padding: max(34px, 6vh) 28px; color: #fff; flex: none;
  background: #57a012;
  overflow: hidden;
  min-height: 42vh;
  display: flex; flex-direction: column; justify-content: center;
}
.auth-hero .hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 28%; z-index: 0; }
.auth-hero .hero-ov { position: absolute; inset: 0; z-index: 1; background: linear-gradient(165deg, rgba(35,64,6,.72), rgba(68,124,12,.66) 55%, rgba(52,98,8,.85)); }
.auth-hero > .toprow, .auth-hero > .hello, .auth-hero > .hello-big { position: relative; z-index: 2; }
.auth-hero .toprow { display: flex; align-items: center; justify-content: space-between; margin-bottom: 26px; }
.auth-hero .wm { display: flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 800; font-size: 18px; letter-spacing: -.5px; }
.auth-hero .wm .ball { width: 22px; height: 22px; border-radius: 50%; background: radial-gradient(circle at 32% 30%, #fff 0 22%, transparent 23%), var(--brand); }
/* logo animada (bola + check separados do texto) */
.logo-anim { display: flex; align-items: center; gap: 14px; }
.logo-anim .lg-mark { position: relative; width: 66px; height: 66px; flex: none; }
.logo-anim .lg-mark { position: relative; width: 66px; height: 66px; flex: none; }
.logo-anim .lg-ball {
  width: 100%; height: 100%; object-fit: contain;
  filter: drop-shadow(0 6px 7px rgba(0,0,0,.32)); transform-origin: center bottom;
  animation: ballRoll 1s cubic-bezier(.25,.7,.35,1) both, ballBounce 1.05s cubic-bezier(.3,.05,.5,1) 1.1s infinite;
}
.logo-anim .lg-check {
  position: absolute; right: -5px; bottom: -3px; width: 46%; height: 46%; object-fit: contain;
  filter: drop-shadow(0 2px 3px rgba(0,0,0,.3));
  transform-origin: center;
  animation: checkPop .5s cubic-bezier(.2,1.5,.4,1) .9s both, checkClick 2.4s ease-in-out 1.6s infinite;
}
.logo-anim .lg-check::after { content: ""; }
.logo-anim .lg-text { height: 46px; width: auto; object-fit: contain; animation: textIn .7s ease .35s both; }
@keyframes ballRoll {
  0% { transform: translateX(-46px) rotate(-360deg); opacity: 0; }
  60% { transform: translateX(0) rotate(0deg); opacity: 1; }
  75% { transform: translateY(-9px) rotate(12deg); }
  88% { transform: translateY(0) rotate(0deg); }
  94% { transform: translateY(-4px); }
  100% { transform: translateY(0); }
}
@keyframes ballBounce {
  0%   { transform: translateY(0) scaleY(1); }
  10%  { transform: translateY(0) scaleY(.86); }
  35%  { transform: translateY(-26px) scaleY(1.06); }
  55%  { transform: translateY(0) scaleY(.9); }
  62%  { transform: translateY(0) scaleY(1.04); }
  100% { transform: translateY(0) scaleY(1); }
}
@keyframes ballSpin {
  0%, 62% { transform: rotate(0deg); }
  82%, 100% { transform: rotate(360deg); }
}
@keyframes checkPop {
  0% { transform: scale(0) rotate(-50deg); opacity: 0; }
  70% { transform: scale(1.25) rotate(6deg); opacity: 1; }
  100% { transform: scale(1) rotate(0deg); opacity: 1; }
}
@keyframes checkClick {
  0%, 70%, 100% { transform: scale(1); }
  78% { transform: scale(.74); }
  86% { transform: scale(1.18); }
  93% { transform: scale(.96); }
}
.logo-anim .lg-mark .ripple {
  position: absolute; right: -5px; bottom: -3px; width: 46%; height: 46%;
  border-radius: 50%; border: 2px solid rgba(160,230,40,.9);
  opacity: 0; pointer-events: none;
  animation: checkRipple 2.4s ease-out 1.6s infinite;
}
@keyframes checkRipple {
  0%, 78% { transform: scale(1); opacity: 0; }
  82% { opacity: .8; }
  100% { transform: scale(2); opacity: 0; }
}
@keyframes textIn { from { opacity: 0; transform: translateX(-14px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  .logo-anim .lg-mark, .logo-anim .lg-ball, .logo-anim .lg-check, .logo-anim .lg-text { animation-duration: .01ms; animation-iteration-count: 1; }
}
.auth-hero .t-btn { position: absolute; top: max(20px, 4vh); right: 22px; z-index: 3; width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: rgba(255,255,255,.14); color: #fff; border: none; cursor: pointer; }
.auth-hero .t-btn .msym { font-size: 20px; }
.auth-hero .hello { font-size: 28px; font-weight: 500; line-height: 1.12; opacity: .9; }
.auth-hero .hello-big { font-family: var(--font-display); font-weight: 800; font-size: 42px; line-height: 1.02; letter-spacing: -1.2px; }
.auth-sheet {
  flex: 1; background: var(--surface); margin-top: -42px;
  border-radius: 42px 42px 0 0; padding: 36px 26px 26px;
  display: flex; flex-direction: column; position: relative; z-index: 2;
}
.auth-sheet form { display: flex; flex-direction: column; flex: 1; }
.auth-photo { display: flex; flex-direction: column; align-items: center; gap: 10px; margin-bottom: 22px; }
.auth-photo .drop {
  width: 84px; height: 84px; border-radius: 50%;
  border: 2px dashed var(--line); display: grid; place-items: center;
  color: var(--faint); cursor: pointer; background: var(--surface-2);
  overflow: hidden; transition: border-color .2s, transform .15s;
}
.auth-photo .drop:hover { border-color: var(--brand-strong); transform: scale(1.04); }
.auth-photo .drop img { width: 100%; height: 100%; object-fit: cover; }
.auth-photo input[type=file] { display: none; }

/* input sublinhado (estilo referência) */
.uline { position: relative; margin-bottom: 22px; }
.uline > label { display: block; font-size: 14px; font-weight: 800; color: var(--brand-text); margin-bottom: 3px; letter-spacing: .2px; }
.uline input {
  width: 100%; border: none; border-bottom: 2px solid var(--line); background: transparent;
  padding: 8px 32px 9px 0; font-size: 16.5px; color: var(--text); font-weight: 600;
}
.uline input::placeholder { color: var(--faint); font-weight: 500; }
.uline input:focus { outline: none; border-bottom-color: var(--brand-strong); }
.uline .tic {
  position: absolute; right: 0; bottom: 6px; width: 28px; height: 28px;
  display: grid; place-items: center; color: var(--faint);
  background: none; border: none; cursor: pointer; transition: color .15s, opacity .15s;
}
.uline .tic .msym { font-size: 21px; }
.uline .tic.check { opacity: 0; color: var(--brand-text); pointer-events: none; }
.uline.valid .tic.check { opacity: 1; }
.uline.taken input { border-bottom-color: var(--live); }
#uline-user .tic { top: 25px; bottom: auto; }
.uline-msg { display: block; margin-top: 6px; font-size: 12px; line-height: 1.35; color: var(--faint); }
.uline.valid .uline-msg { color: var(--brand-text); }
.uline.taken .uline-msg { color: var(--live); }

.auth-link { align-self: flex-end; font-size: 14px; font-weight: 700; color: var(--muted); cursor: pointer; background: none; border: none; margin: -8px 0 6px; }
.auth-cta { margin-top: auto; padding-top: 20px; }
.auth-swap { text-align: center; margin-top: 16px; font-size: 14.5px; color: var(--muted); }
.auth-swap b { color: var(--brand-text); cursor: pointer; }
.btn-grad { background: #57a012; color: #fff; }

/* placar input (número grande) */
.score-input {
  width: 56px; height: 56px; text-align: center;
  font-family: var(--font-display); font-size: 28px; font-weight: 800;
  background: var(--bg-2); color: var(--text);
  border: 2px solid var(--line); border-radius: var(--r-sm);
  transition: border-color .2s, box-shadow .2s;
}
.score-input:focus { outline: none; border-color: var(--brand-strong); box-shadow: 0 0 0 4px rgba(182,242,0,.22); }
.score-input:disabled { opacity: .55; cursor: not-allowed; }

/* upload de foto */
.photo-pick {
  display: flex; flex-direction: column; align-items: center; gap: 10px;
}
.photo-pick input[type=file] { display: none; }
.photo-pick .drop {
  width: 96px; height: 96px; border-radius: 50%;
  border: 2px dashed var(--line); display: grid; place-items: center;
  color: var(--faint); font-size: 12px; text-align: center; cursor: pointer;
  background: var(--surface-2); overflow: hidden; transition: border-color .2s, transform .15s;
}
.photo-pick .drop:hover { border-color: var(--brand); transform: scale(1.03); }
.photo-pick .drop img { width: 100%; height: 100%; object-fit: cover; }

.avatar-pick { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.avatar-pick button {
  width: 42px; height: 42px; font-size: 22px; border-radius: 50%;
  background: var(--surface-2); border: 2px solid var(--line); cursor: pointer;
  transition: transform .15s, border-color .15s;
}
.avatar-pick button:hover { transform: scale(1.1); }
.avatar-pick button.sel { border-color: var(--brand-strong); background: rgba(182,242,0,.18); }
.avatar-pick button .msym { font-size: 22px; color: var(--muted); }
.avatar-pick button.sel .msym { color: var(--brand-text); }

/* checkbox (aceite de termos) */
.check { display: flex; gap: 11px; align-items: flex-start; cursor: pointer; font-size: 13.5px; color: var(--muted); line-height: 1.5; }
.check input { position: absolute; opacity: 0; width: 0; height: 0; }
.check .box { flex: none; width: 22px; height: 22px; border-radius: 7px; border: 2px solid var(--line); background: var(--bg-2); display: grid; place-items: center; transition: background .15s, border-color .15s; margin-top: 1px; }
.check .box .msym { font-size: 16px; color: var(--brand-ink); opacity: 0; transform: scale(.5); transition: opacity .15s, transform .15s; }
.check input:checked + .box { background: var(--brand); border-color: var(--brand); }
.check input:checked + .box .msym { opacity: 1; transform: scale(1); }
.check input:focus-visible + .box { box-shadow: 0 0 0 4px rgba(182,242,0,.25); }
.check b { color: var(--text); }

/* ============ 6. BOTÕES ============ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 15px 22px; border: none; border-radius: var(--r-pill);
  font-size: 16px; font-weight: 700; letter-spacing: .2px;
  cursor: pointer; transition: transform .12s, box-shadow .2s, background .2s, opacity .2s;
  user-select: none;
}
.btn:active { transform: scale(.96); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.block { width: 100%; }
.btn.lg { padding: 18px 24px; font-size: 17px; }
.btn.sm { padding: 10px 15px; font-size: 14px; }

.btn-primary { background: var(--brand); color: var(--brand-ink); box-shadow: 0 8px 22px -8px rgba(182,242,0,.6); }
.btn-primary:hover { box-shadow: 0 12px 30px -6px rgba(182,242,0,.75); }
.btn-gold { background: var(--gold); color: #1c1500; box-shadow: 0 8px 24px -8px rgba(233,178,0,.5); }
.btn-ghost { background: var(--surface-2); color: var(--text); border: 1px solid var(--line); }
.btn-ghost:hover { border-color: var(--brand-strong); color: var(--brand-text); }
.btn-outline { background: transparent; color: var(--brand-text); border: 1.5px solid var(--brand-text); }
.btn-danger { background: rgba(255,90,77,.15); color: var(--live); border: 1px solid rgba(255,90,77,.4); }
.btn-dark { background: var(--ink); color: #f3f7ec; }
.btn-dark:hover { background: var(--ink-2); }

.btn-link { background: none; border: none; color: var(--brand-text); font-weight: 700; cursor: pointer; font-size: 14px; }

/* segmented control */
.segmented {
  display: inline-flex; background: var(--bg-2); border: 1px solid var(--line);
  border-radius: var(--r-pill); padding: 4px; gap: 2px;
}
.segmented button {
  border: none; background: none; color: var(--muted); cursor: pointer;
  padding: 9px 18px; border-radius: var(--r-pill); font-weight: 700; font-size: 14.5px;
  transition: background .2s, color .2s;
}
.segmented button.active { background: var(--brand); color: var(--brand-ink); }
/* segmented deslizante (muitas abas) */
.segmented.seg-scroll { display: flex; width: 100%; overflow-x: auto; justify-content: flex-start; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.segmented.seg-scroll::-webkit-scrollbar { display: none; }
.segmented.seg-scroll button { flex: none; white-space: nowrap; }

/* ============ 7. COMPONENTES DE BOLÃO ============ */

/* card de jogo */
.match {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r); padding: var(--sp-4); box-shadow: var(--shadow);
  transition: transform .15s, border-color .2s;
}
.match .meta {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 13px; color: var(--muted); margin-bottom: var(--sp-3);
}
.match .meta .when { font-weight: 700; }
.match .teams {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: var(--sp-2);
}
.team {
  display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center;
}
.team .flag {
  width: 54px; height: 38px; border-radius: 9px; object-fit: cover;
  box-shadow: 0 4px 12px -4px rgba(20,30,10,.30); border: 1px solid var(--line);
  background: var(--surface-2);
}
.team .nm { font-size: 15px; font-weight: 700; }
.team .cod { font-family: var(--font-display); font-size: 18px; font-weight: 800; letter-spacing: .5px; }
.match .vs {
  font-family: var(--font-display); font-size: 14px; font-weight: 800; color: var(--faint);
  padding: 0 4px;
}
.match .score-show {
  font-family: var(--font-display); font-size: 30px; font-weight: 800; letter-spacing: .5px;
  display: flex; gap: 8px; align-items: center; color: var(--text);
}

.match .teams .score-input { margin-top: 9px; }
/* linha de input de placar p/ palpite */
.guess-row {
  display: flex; align-items: center; justify-content: center; gap: 12px;
  margin-top: var(--sp-4); padding-top: var(--sp-4); border-top: 1px dashed var(--line);
}
.guess-row .x { font-family: var(--font-display); color: var(--faint); font-size: 20px; font-weight: 800; }
.guess-status { text-align: center; font-size: 13.5px; margin-top: 10px; min-height: 16px; }
.guess-status.ok { color: var(--brand-text); }
.guess-status.lock { color: #9a7400; }

/* tag de pontos ganhos */
.pts-tag {
  display: inline-flex; align-items: center; gap: 5px; padding: 5px 12px;
  border-radius: var(--r-pill); font-weight: 800; font-size: 13px;
}
.pts-exato { background: rgba(182,242,0,.24); color: var(--brand-text); }
.pts-saldo { background: rgba(182,242,0,.15); color: var(--brand-text); }
.pts-resultado { background: rgba(233,178,0,.18); color: #9a7400; }
.pts-erro { background: rgba(255,90,77,.14); color: var(--live); }
.pts-pendente { background: var(--surface-2); color: var(--muted); }

/* RANKING */
.podium {
  display: grid; grid-template-columns: 1fr 1.18fr 1fr; gap: 10px; align-items: end;
  margin: var(--sp-4) 0 var(--sp-5); padding-top: 20px;
}
.podium .spot { display: flex; flex-direction: column; align-items: center; }
.podium .av-wrap { position: relative; display: grid; place-items: center; margin-bottom: -20px; z-index: 2; }
.podium .p1 .av-wrap::before { content: ""; position: absolute; inset: -7px; border-radius: 50%; border: 2.5px solid var(--brand); animation: haloRing 1.8s ease-out infinite; pointer-events: none; }
.podium .trophy { position: absolute; top: -13px; left: 50%; transform: translateX(-50%); width: 32px; height: 32px; border-radius: 50%; background: var(--gold); color: #3a2900; display: grid; place-items: center; box-shadow: 0 5px 12px -3px rgba(0,0,0,.35); z-index: 4; animation: trophyBounce 1.6s ease-in-out infinite; }
.podium .trophy .msym { font-size: 19px; }
.podium .spot .avatar {
  border-width: 3px;
  background: radial-gradient(circle at 50% 30%, #43571f, var(--ink) 70%); border-color: var(--ink);
  box-shadow: var(--shadow); animation: pop .5s cubic-bezier(.2,.9,.3,1.4) both;
}
.podium .spot .avatar .msym { color: var(--brand); }
.podium .spot .avatar.ring { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(182,242,0,.25); }
.podium .spot:nth-child(1) .avatar { animation-delay: .16s; }
.podium .spot:nth-child(2) .avatar { animation-delay: .28s; }
.podium .spot:nth-child(3) .avatar { animation-delay: .22s; }
.podium .stand {
  width: 100%; background: var(--surface);
  border: 1px solid var(--line); border-bottom: none;
  border-radius: var(--r-lg) var(--r-lg) 0 0; padding: 22px 6px 16px;
  display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 3px;
  box-shadow: inset 0 -20px 26px -14px rgba(20,30,10,.45);
  transform-origin: bottom; animation: podiumRise .6s cubic-bezier(.2,.8,.2,1) both;
}
.podium .spot:nth-child(1) .stand { animation-delay: .06s; }
.podium .spot:nth-child(2) .stand { animation-delay: .18s; }
.podium .spot:nth-child(3) .stand { animation-delay: .12s; }
.podium .p1 .stand { height: 152px; background: var(--ink); border-color: var(--ink); box-shadow: inset 0 -24px 30px -14px rgba(0,0,0,.75), 0 -12px 34px -12px rgba(20,30,10,.55); }
.podium .p2 .stand { height: 116px; }
.podium .p3 .stand { height: 116px; }
.podium .crown { font-size: 18px; line-height: 1; margin-bottom: 1px; }
.podium .ranknum { font-family: var(--font-display); font-size: 27px; font-weight: 800; line-height: 1; }
.podium .p1 .ranknum { color: var(--brand); }
.podium .p1 .nm { color: #f3f7ec; }
.podium .p2 .ranknum { color: #6b7280; }
.podium .p3 .ranknum { color: #b06a2c; }
.podium .nm { font-size: 13px; font-weight: 700; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text); }
.podium .pts { font-family: var(--font-display); font-size: 20px; font-weight: 800; color: var(--text); }
.podium .p1 .pts { color: var(--brand); }

/* linha de ranking / participante */
.rank-row {
  display: flex; align-items: center; gap: 13px;
  padding: 13px 15px; border-radius: var(--r);
  background: var(--surface); border: 1px solid var(--line-soft);
  box-shadow: 0 8px 20px -16px rgba(20,30,10,.4);
  transition: transform .15s, border-color .2s, box-shadow .2s;
}
.rank-row + .rank-row { margin-top: 10px; }
.rank-row:hover { transform: translateY(-2px); box-shadow: var(--shadow); border-color: var(--line); }
.rank-row.me { border-color: var(--brand-strong); background: rgba(182,242,0,.13); }
.rank-row .pos {
  font-family: var(--font-display); font-size: 22px; font-weight: 800; width: 24px; text-align: center;
  color: var(--faint); flex: none;
}
.rank-row.top .pos { color: var(--gold); }
.rank-row .info { flex: 1; min-width: 0; }
.rank-row .nmline { display: flex; align-items: center; gap: 8px; min-width: 0; }
.rank-row .nmline .nm { font-weight: 800; font-size: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.rank-row .info .nm { font-weight: 700; font-size: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank-row .info .sub { font-size: 12.5px; color: var(--muted); margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rank-row .score { text-align: right; flex: none; }
.rank-row .score .n { font-family: var(--font-display); font-size: 26px; font-weight: 800; color: var(--text); line-height: 1; }
.rank-row .score .u { font-size: 11px; color: var(--faint); text-transform: uppercase; letter-spacing: .5px; }

/* stat tiles */
.stats-grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-3); }
.stat {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r); padding: var(--sp-4); text-align: center;
}
.stat .n { font-family: var(--font-display); font-size: 38px; font-weight: 800; line-height: 1; }
.stat .n.brand { color: var(--brand-text); } .stat .n.gold { color: #9a7400; }
.stat .n.lime { color: var(--brand-text); } .stat .n.blue { color: var(--blue); }
.stat .l { font-size: 12.5px; color: var(--muted); text-transform: uppercase; letter-spacing: .5px; margin-top: 5px; }

/* barra de progresso */
.bar { height: 8px; border-radius: var(--r-pill); background: var(--bg-2); overflow: hidden; }
.bar > i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--brand-strong), var(--brand)); transition: width .8s cubic-bezier(.2,.8,.2,1); }

/* estado vazio */
.empty { text-align: center; color: var(--muted); padding: var(--sp-6) var(--sp-4); }
.empty .ico { font-size: 40px; margin-bottom: 8px; }

/* espaços publicitários */
.ad-slot { display: block; margin: 16px auto; border-radius: 16px; overflow: hidden; width: 100%; }
.ad-slot img { width: 100%; height: auto; display: block; }
.ad-ph { display: grid; place-items: center; border: 2px dashed var(--line); background: var(--surface-2); color: var(--faint); font-size: 11px; font-weight: 800; letter-spacing: .6px; text-transform: uppercase; }
.ad-ph.s-topo, .ad-ph.s-palpites { height: 92px; }
.ad-ph.s-meio { height: 180px; }
.ad-ph.s-rodape { height: 52px; }
.premios-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.premios-grid img { width: 100%; aspect-ratio: 4/3; object-fit: cover; border-radius: 14px; border: 1px solid var(--line); }
.swatches { display: flex; flex-wrap: wrap; gap: 10px; }
.swatches .sw { width: 34px; height: 34px; border-radius: 50%; cursor: pointer; border: 3px solid transparent; box-shadow: 0 0 0 1px var(--line) inset; transition: transform .12s; }
.swatches .sw:hover { transform: scale(1.12); }
.swatches .sw.sel { border-color: var(--text); }
.prem-thumb { position: relative; }
.prem-thumb button { position: absolute; top: 4px; right: 4px; width: 24px; height: 24px; border-radius: 50%; border: none; background: rgba(0,0,0,.6); color: #fff; cursor: pointer; display: grid; place-items: center; }
.prem-thumb button .msym { font-size: 16px; }

/* cabeçalho de data (lista por dia) */
.date-head {
  display: flex; align-items: center; gap: 10px; margin: var(--sp-5) 0 var(--sp-3);
  position: sticky; top: var(--header-h); z-index: 20;
  padding: 6px 0; background: linear-gradient(180deg, var(--bg) 60%, transparent);
}
.date-head .d {
  font-family: var(--font-display); font-size: 18px; font-weight: 800;
  letter-spacing: -.4px; color: var(--text); white-space: nowrap;
}
.date-head .dow { color: var(--brand-text); }
.date-head .ln { flex: 1; height: 1px; background: var(--line); }
.date-head .n { font-size: 12.5px; color: var(--faint); white-space: nowrap; }

/* time "a definir" (placeholder eliminatórias) */
.team .flag.tbd {
  display: grid; place-items: center; color: var(--faint); font-size: 20px;
  background: repeating-linear-gradient(45deg, var(--surface-2), var(--surface-2) 6px, var(--surface) 6px, var(--surface) 12px);
}
.match.tbd-match { border-style: dashed; opacity: .92; }

/* select de time (admin eliminatórias) */
.team-select {
  width: 100%; padding: 10px; border-radius: var(--r-sm);
  background: var(--bg-2); color: var(--text); border: 1.5px solid var(--line);
  font-size: 14px; font-weight: 600;
}
.team-select:focus { outline: none; border-color: var(--brand-strong); }

/* ============ 8. UTILITÁRIOS / ANIMAÇÕES ============ */
.center-screen { min-height: 100dvh; display: flex; flex-direction: column; justify-content: center; }
.text-c { text-align: center; } .text-muted { color: var(--muted); }
.mt-1{margin-top:var(--sp-1)} .mt-2{margin-top:var(--sp-2)} .mt-3{margin-top:var(--sp-3)} .mt-4{margin-top:var(--sp-4)} .mt-5{margin-top:var(--sp-5)}
.mb-2{margin-bottom:var(--sp-2)} .mb-3{margin-bottom:var(--sp-3)} .mb-4{margin-bottom:var(--sp-4)}
.hidden { display: none !important; }
.full { width: 100%; }

.toast {
  position: fixed; left: 50%; bottom: calc(var(--nav-h) + 18px); transform: translateX(-50%) translateY(20px);
  display: flex; align-items: center; gap: 9px;
  background: var(--surface); color: var(--text); border: 1.5px solid var(--line); border-left-width: 5px;
  padding: 13px 18px; border-radius: 14px; font-weight: 600; font-size: 14px;
  box-shadow: var(--shadow-lg); z-index: 100; opacity: 0; pointer-events: none;
  transition: opacity .3s, transform .3s; max-width: 90%;
}
.toast .msym { font-size: 21px; flex: none; }
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast.ok   { border-left-color: var(--brand-strong); } .toast.ok .msym { color: var(--brand-text); }
.toast.err  { border-left-color: var(--live); }         .toast.err .msym { color: var(--live); }
.toast.warn { border-left-color: var(--gold); }         .toast.warn .msym { color: #9a7400; }
.toast.info { border-left-color: var(--blue); }         .toast.info .msym { color: var(--blue); }

@keyframes fadeUp { from { transform: translateY(14px); } to { transform: none; } }
@keyframes podiumRise { from { transform: translateY(28px) scaleY(.8); } to { transform: none; } }
@keyframes haloRing { 0% { transform: scale(.92); opacity: .85; } 100% { transform: scale(1.32); opacity: 0; } }
@keyframes trophyBounce { 0%,100% { transform: translateX(-50%) translateY(0) rotate(-7deg); } 50% { transform: translateX(-50%) translateY(-5px) rotate(7deg); } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pulse { 0%,100% { opacity: 1; transform: scale(1);} 50% { opacity: .3; transform: scale(.7);} }
@keyframes pop { 0% { transform: scale(.85);} 60% { transform: scale(1.06);} 100% { transform: scale(1);} }
.pop { animation: pop .4s cubic-bezier(.2,.9,.3,1.4) both; }

.stagger > * { animation: fadeUp .5s ease both; }
.stagger > *:nth-child(1){animation-delay:.04s} .stagger > *:nth-child(2){animation-delay:.10s}
.stagger > *:nth-child(3){animation-delay:.16s} .stagger > *:nth-child(4){animation-delay:.22s}
.stagger > *:nth-child(5){animation-delay:.28s} .stagger > *:nth-child(6){animation-delay:.34s}
.stagger > *:nth-child(7){animation-delay:.40s} .stagger > *:nth-child(8){animation-delay:.46s}
.stagger > *:nth-child(n+9){animation-delay:.5s}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* confete (acerto exato) */
.confetti { position: fixed; inset: 0; pointer-events: none; z-index: 90; overflow: hidden; }
.confetti i { position: absolute; top: -12px; width: 9px; height: 14px; border-radius: 2px; animation: fall 1.5s linear forwards; }
@keyframes fall { to { transform: translateY(105vh) rotate(540deg); opacity: .2; } }

/* ===== OVERLAY DE LOADING (bola quicando + frase) ===== */
.load-ov {
  position: fixed; inset: 0; z-index: 2000;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 26px;
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  opacity: 0; pointer-events: none; transition: opacity .25s ease;
}
.load-ov.show { opacity: 1; pointer-events: auto; }
.load-ov .lo-stage { position: relative; width: 76px; height: 92px; }
.load-ov .lo-ball {
  position: absolute; left: 0; bottom: 14px; width: 60px; height: 60px; left: 8px;
  object-fit: contain; transform-origin: center bottom;
  filter: drop-shadow(0 6px 6px rgba(0,0,0,.3));
  animation: loadBounce .85s cubic-bezier(.3,.05,.5,1) infinite;
}
.load-ov .lo-shadow {
  position: absolute; left: 50%; bottom: 8px; width: 48px; height: 11px; transform: translateX(-50%);
  background: radial-gradient(ellipse, rgba(0,0,0,.28), transparent 70%);
  border-radius: 50%; animation: loadShadow .85s cubic-bezier(.3,.05,.5,1) infinite;
}
.load-ov .lo-text { color: var(--text); font-weight: 700; font-size: 16px; text-align: center; max-width: 80%; letter-spacing: .2px; }
.load-ov .lo-text::after { content: ""; animation: loadDots 1.4s steps(1,end) infinite; }
@keyframes loadBounce {
  0%   { transform: translateY(0) scaleY(1) scaleX(1); }
  12%  { transform: translateY(0) scaleY(.82) scaleX(1.08); }
  45%  { transform: translateY(-46px) scaleY(1.05) scaleX(.97); }
  78%  { transform: translateY(0) scaleY(.86) scaleX(1.06); }
  90%  { transform: translateY(0) scaleY(1.03) scaleX(.99); }
  100% { transform: translateY(0) scaleY(1) scaleX(1); }
}
@keyframes loadShadow {
  0%, 100% { transform: translateX(-50%) scale(1); opacity: .55; }
  45% { transform: translateX(-50%) scale(.55); opacity: .25; }
}
@keyframes loadDots { 0%{content:"";} 25%{content:".";} 50%{content:"..";} 75%{content:"...";} }
@media (prefers-reduced-motion: reduce) { .load-ov .lo-ball, .load-ov .lo-shadow { animation-duration: .01ms; } }

/* ===== SPLASH PWA (abertura animada, centralizada) ===== */
.app-splash {
  position: fixed; inset: 0; z-index: 4000;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 22px;
  background: #57a012; color: #fff;
  opacity: 1; transition: opacity .5s ease;
}
.app-splash.hide { opacity: 0; pointer-events: none; }
.app-splash .sp-mark { position: relative; width: 92px; height: 92px; }
.app-splash .sp-ball { width: 100%; height: 100%; object-fit: contain; transform-origin: center bottom; filter: drop-shadow(0 8px 8px rgba(0,0,0,.3)); animation: spSplashBounce 1s cubic-bezier(.3,.05,.5,1) infinite; }
.app-splash .sp-check { position: absolute; right: -6px; bottom: -4px; width: 44%; height: 44%; object-fit: contain; filter: drop-shadow(0 2px 3px rgba(0,0,0,.3)); animation: checkPop .5s cubic-bezier(.2,1.5,.4,1) .25s both; }
.app-splash .sp-text { height: 40px; width: auto; object-fit: contain; animation: textIn .6s ease .2s both; }
.app-splash .sp-load { width: 36px; height: 36px; border-radius: 50%; border: 3px solid rgba(255,255,255,.3); border-top-color: #fff; animation: spSpin .8s linear infinite; }
@keyframes spSplashBounce { 0%{transform:translateY(0) scaleY(1);} 12%{transform:translateY(0) scaleY(.82);} 45%{transform:translateY(-40px) scaleY(1.05);} 78%{transform:translateY(0) scaleY(.86);} 90%{transform:translateY(0) scaleY(1.03);} 100%{transform:translateY(0) scaleY(1);} }
@keyframes spSpin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .app-splash .sp-ball, .app-splash .sp-load { animation: none; } }

/* ===== TOOLTIP INSTALAR APP ===== */
.install-tip {
  position: fixed; left: 50%; transform: translateX(-50%) translateY(20px);
  bottom: calc(var(--nav-h) + 18px); z-index: 90;
  display: flex; align-items: center; gap: 11px;
  background: var(--ink); color: #f3f7ec; padding: 11px 12px 11px 16px;
  border-radius: var(--r-pill); box-shadow: var(--shadow-lg);
  opacity: 0; pointer-events: none; transition: opacity .3s, transform .3s; max-width: calc(100% - 32px);
}
.install-tip.show { opacity: 1; pointer-events: auto; transform: translateX(-50%) translateY(0); }
.install-tip .it-txt { font-size: 13.5px; font-weight: 600; line-height: 1.25; }
.install-tip .it-txt b { color: var(--brand); }
.install-tip .it-go { background: var(--brand); color: var(--brand-ink); border: none; border-radius: var(--r-pill); font-weight: 800; font-size: 13px; padding: 9px 14px; cursor: pointer; white-space: nowrap; font-family: inherit; }
.install-tip .it-x { background: none; border: none; color: rgba(243,247,236,.6); cursor: pointer; display: grid; place-items: center; padding: 4px; }
.install-tip .it-x .msym { font-size: 18px; }
/* na tela de login (sem nav), encosta no rodapé */
body:has(.auth) .install-tip { bottom: 18px; }

/* ============ 9. RESPONSIVO (tablet / desktop) ============ */
@media (min-width: 760px) {
  :root { --app-max: 720px; }
  .page { padding-left: 24px; padding-right: 24px; }
  /* só os cards de JOGOS viram colunas; ranking/histórico ficam em lista */
  #lista > .stack,
  #lista-result > .stack,
  #lista-elim > .stack {
    display: grid; grid-template-columns: 1fr 1fr; gap: 12px; align-items: start;
  }
  #lista > .stack > *, #lista-result > .stack > *, #lista-elim > .stack > * { margin-top: 0 !important; }
  .premios-grid { grid-template-columns: repeat(3, 1fr); }
  .auth { max-width: 460px; }
}
@media (min-width: 1120px) {
  :root { --app-max: 1040px; }
  #lista > .stack, #lista-result > .stack, #lista-elim > .stack { grid-template-columns: 1fr 1fr 1fr; }
}

/* ----- LOGIN em split no desktop ----- */
@media (min-width: 900px) {
  body:has(.auth) { display: flex; align-items: center; justify-content: center; padding: 24px; }
  .auth {
    flex-direction: row; max-width: 1000px; min-height: 0; height: min(680px, 90vh);
    margin: auto; border-radius: 30px; overflow: hidden; box-shadow: var(--shadow-lg);
  }
  .auth-hero {
    width: 45%; flex: none; padding: 44px 40px; display: flex; flex-direction: column; justify-content: center; min-height: 0;
  }
  .auth-hero .toprow { margin-bottom: 26px; }
  .auth-hero .hello { font-size: 30px; }
  .auth-hero .hello-big { font-size: 48px; }
  .auth-sheet {
    width: 55%; flex: none; margin: 0; border-radius: 0;
    overflow: auto; padding: 40px 48px; display: flex; flex-direction: column; justify-content: safe center;
  }
  .auth-sheet form { flex: none; }
  .auth-sheet .auth-cta { margin-top: 28px; }
}
