/* CloudGames — visual dos recursos do lobby (missões, baú, perfil, loja, amigos, torneios…) */

/* barra de baixo com 5 abas */
.bottom-nav { grid-template-columns: repeat(5, 1fr); }
.bottom-nav button { font-size: .78rem; position: relative; padding: 6px 2px; }
.nav-dot { position: absolute; top: 4px; right: calc(50% - 20px); width: 10px; height: 10px; border-radius: 50%; background: #ff4d6d; box-shadow: 0 0 0 2px var(--card); display: none; }
.nav-dot.on { display: block; }

/* nível no avatar, molduras e nome colorido */
.lvb { position: absolute; left: -5px; bottom: -5px; font-style: normal; font-size: .62rem; font-weight: 800; line-height: 1; min-width: 17px; height: 17px; padding: 0 3px;
  border-radius: 9px; background: var(--primary); color: #fff; display: grid; place-items: center; box-shadow: 0 0 0 2px #fff; font-family: inherit; }
.players-bar.compact .lvb { min-width: 14px; height: 14px; font-size: .55rem; left: -4px; bottom: -4px; }
.ncg { -webkit-background-clip: text; background-clip: text; color: transparent !important; font-weight: 800; }
.av.fr { z-index: 0; }
.fr-ouro { box-shadow: 0 0 0 3px #f5c542, 0 0 10px rgba(245,197,66,.7) !important; }
.fr-arco { box-shadow: 0 0 0 2px #ff4d6d, 0 0 0 4px #ffc83d, 0 0 0 6px #2ecc71, 0 0 0 8px #3a86ff !important; }
.fr-fogo { box-shadow: 0 0 0 3px #ff5a1f, 0 0 12px 3px #ffb02e !important; animation: frFire 1.2s ease-in-out infinite alternate; }
.fr-gelo { box-shadow: 0 0 0 3px #9be7ff, 0 0 12px #c9f3ff !important; }
.fr-neon { box-shadow: 0 0 0 2px #fff, 0 0 0 4px #c13bff, 0 0 14px #c13bff !important; animation: frPulse 1.6s ease-in-out infinite; }
.fr-coracao { box-shadow: 0 0 0 3px #ff5cb8, 0 0 0 5px #ffd1ea !important; }
.fr-estrela { box-shadow: 0 0 0 3px #ffd34d, 0 0 14px 2px rgba(255,211,77,.8) !important; }
.fr-diamante { box-shadow: 0 0 0 2px #fff, 0 0 0 5px #6ee7ff, 0 0 16px #6ee7ff !important; animation: frPulse 2.2s ease-in-out infinite; }
.fr-bau { box-shadow: 0 0 0 3px #b07d2b, 0 0 0 5px #ffd76a !important; }
.fr-campeao { box-shadow: 0 0 0 3px #ffd700, 0 0 0 6px #ff8c00, 0 0 16px rgba(255,170,0,.8) !important; }
@keyframes frFire { to { box-shadow: 0 0 0 3px #ff2e1f, 0 0 18px 5px #ffcf2e; } }
@keyframes frPulse { 50% { filter: brightness(1.25); } }
@media (prefers-reduced-motion: reduce) { .fr-fogo, .fr-neon, .fr-diamante { animation: none; } }

/* chip do jogador no topo */
.me-chip .nm, .me-chip b { font-weight: 800; }
.me-lv { background: rgba(255,255,255,.25); border-radius: 8px; padding: 0 5px; font-weight: 800; }
.xpbar { display: block; height: 4px; border-radius: 3px; background: rgba(255,255,255,.3); margin-top: 3px; overflow: hidden; min-width: 90px; }
.xpbar i { display: block; height: 100%; background: var(--yellow); border-radius: 3px; }

/* blocos do topo do lobby */
.hub { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin-bottom: 14px; }
.hub:empty { display: none; }
.hub-tile { border: 0; background: var(--card); color: var(--ink); border-radius: 18px; padding: 10px 12px; display: flex; align-items: center; gap: 10px; text-align: left;
  box-shadow: var(--shadow); font: inherit; cursor: pointer; position: relative; min-height: 60px; }
.hub-tile .ht-ic { font-size: 1.7rem; flex: none; }
.hub-tile .ht-tx { display: flex; flex-direction: column; line-height: 1.15; min-width: 0; }
.hub-tile b { font-size: .98rem; }
.hub-tile small { color: var(--muted); font-weight: 600; font-size: .8rem; overflow: hidden; text-overflow: ellipsis; }
.hub-tile.hot { box-shadow: 0 0 0 3px var(--yellow), var(--shadow); }
.hub-tile.hot::after { content: ''; position: absolute; top: 8px; right: 8px; width: 10px; height: 10px; border-radius: 50%; background: #ff4d6d; animation: frPulse 1s infinite; }
.hub-tile.hot .ht-ic { animation: wiggle 1.6s ease-in-out infinite; }
@keyframes wiggle { 0%, 70%, 100% { transform: rotate(0); } 75% { transform: rotate(-12deg); } 85% { transform: rotate(12deg); } }

/* janela deslizante */
.sh-wrap { position: fixed; inset: 0; z-index: 150; background: rgba(20, 10, 50, .5); backdrop-filter: blur(3px); display: flex; align-items: flex-end; justify-content: center; animation: fade .18s; }
.sh-wrap.out { opacity: 0; transition: opacity .17s; }
.sh { background: var(--card); color: var(--ink); width: min(100%, 560px); max-height: min(86dvh, 86vh); border-radius: 26px 26px 0 0; display: flex; flex-direction: column;
  box-shadow: var(--shadow); animation: shUp .26s cubic-bezier(.2,1,.4,1); padding-bottom: env(safe-area-inset-bottom); }
.sh.tall { max-height: min(94dvh, 94vh); }
@media (min-width: 700px) { .sh-wrap { align-items: center; } .sh { border-radius: 26px; } }
@keyframes shUp { from { transform: translateY(40px); opacity: 0; } }
.sh-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px 8px; font-size: 1.15rem; }
.sh-x { border: 0; background: var(--soft); color: var(--muted); width: 34px; height: 34px; border-radius: 50%; font-size: 1rem; cursor: pointer; }
.sh-body { overflow-y: auto; padding: 4px 16px 18px; overscroll-behavior: contain; }
.sh-body .btn.big { width: 100%; }
.center { text-align: center; }
.small { font-size: .85rem; }

/* barras de progresso */
.pbar { display: block; height: 8px; border-radius: 6px; background: var(--soft); overflow: hidden; margin: 5px 0 3px; }
.pbar i { display: block; height: 100%; background: linear-gradient(90deg, var(--primary), #b05cff); border-radius: 6px; transition: width .4s; }
.pbar.thin { height: 5px; }

/* baú */
.daily { display: flex; flex-direction: column; gap: 10px; align-items: stretch; }
.chest { font-size: 4.2rem; text-align: center; line-height: 1.2; }
.chest.ready { animation: wiggle 1.4s ease-in-out infinite; }
.chest.opening { animation: shake .6s ease-in-out; }
.chest.open { animation: popin .5s cubic-bezier(.2,1.6,.4,1); }
@keyframes shake { 20%, 60% { transform: rotate(-14deg) scale(1.1); } 40%, 80% { transform: rotate(14deg) scale(1.15); } }
@keyframes popin { from { transform: scale(.3); } }
.dd-row { display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; }
.dd { background: var(--soft); border-radius: 12px; padding: 6px 2px; display: flex; flex-direction: column; align-items: center; font-size: .8rem; gap: 1px; }
.dd span { font-size: 1.15rem; }
.dd.got { opacity: .55; }
.dd.now { background: #fff3c4; box-shadow: 0 0 0 2px var(--yellow); color: #5a4300; }
.dd em { font-size: .6rem; font-style: normal; color: var(--muted); text-align: center; }
@media (max-width: 380px) { .dd small { font-size: .62rem; } }

/* missões */
.mis { display: flex; flex-direction: column; gap: 10px; }
.mi { display: flex; align-items: center; gap: 10px; background: var(--soft); border-radius: 16px; padding: 10px 12px; }
.mi.ok { background: #fff3c4; color: #4a3b00; }
.mi.got { opacity: .6; }
.mi-ic { font-size: 1.6rem; }
.mi-tx { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.mi-tx small { color: var(--muted); }
.mi.ok .mi-tx small { color: #6b5600; }
.mi-st { font-size: 1.4rem; }

/* avisos que descem do topo */
.cgpop { position: fixed; left: 50%; top: max(10px, env(safe-area-inset-top)); z-index: 300; transform: translate(-50%, -140%); transition: transform .3s cubic-bezier(.2,1.3,.4,1);
  background: var(--card); color: var(--ink); border-radius: 18px; padding: 10px 16px 10px 12px; display: flex; align-items: center; gap: 10px; box-shadow: var(--shadow), 0 0 0 3px var(--yellow);
  width: max-content; max-width: min(92vw, 420px); pointer-events: none; }
.cgpop.in { transform: translate(-50%, 0); }
.cgpop-ic { font-size: 2rem; }
.cgpop b { display: block; }
.cgpop small { color: var(--muted); font-weight: 600; }
.cgpop.lvl { box-shadow: var(--shadow), 0 0 0 3px var(--primary); }

/* perfil */
.pf { display: flex; flex-direction: column; gap: 12px; }
.pf-top { display: flex; gap: 14px; align-items: center; }
.av.big { width: 76px; height: 76px; font-size: 2.6rem; }
.pf-id { flex: 1; min-width: 0; }
.pf-name { font-size: 1.45rem; font-weight: 800; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pf-sub { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0; }
.chip { background: var(--soft); border-radius: 20px; padding: 2px 10px; font-weight: 700; font-size: .82rem; border: 0; color: var(--ink); font-family: inherit; }
.chip.code { cursor: pointer; color: var(--primary); }
.chip.on { background: #dff7ea; color: #0b7a4b; }
.pf-xp small { color: var(--muted); font-weight: 600; }
.pf-btns { display: flex; flex-wrap: wrap; gap: 8px; }
.pf-btns .btn { flex: 1 1 140px; }
.pf-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.pf-st { background: var(--soft); border-radius: 14px; padding: 8px; text-align: center; display: flex; flex-direction: column; }
.pf-st b { font-size: 1.15rem; }
.pf-st small { color: var(--muted); font-weight: 600; font-size: .75rem; }
.pf-sec h4 { margin: 6px 0 8px; }
.pf-games { display: flex; flex-direction: column; gap: 6px; }
.pg { display: grid; grid-template-columns: 34px 1fr auto; grid-template-rows: auto auto; align-items: center; column-gap: 8px; background: var(--soft); border-radius: 12px; padding: 6px 10px; }
.pg-ic { grid-row: span 2; font-size: 1.5rem; }
.pg small { grid-column: 2; color: var(--muted); font-weight: 600; }
.pg .tier { grid-column: 3; grid-row: 1 / span 2; font-size: .8rem; font-weight: 800; }
.pf-ach { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px; }
.ac { background: var(--soft); border-radius: 14px; padding: 8px; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 1px; filter: grayscale(1); opacity: .6; }
.ac.got { filter: none; opacity: 1; background: #fff6d6; color: #4a3b00; }
.ac.got.t2 { background: #e8f0ff; color: #1d3c7a; }
.ac.got.t3 { background: linear-gradient(135deg, #fff1b8, #ffd6f0); color: #5a2a3d; }
.ac-ic { font-size: 1.7rem; }
.ac b { font-size: .85rem; line-height: 1.1; }
.ac small { font-size: .7rem; opacity: .8; font-weight: 600; }
.ac .pbar { width: 100%; }
.pf-hist { display: flex; flex-direction: column; gap: 6px; }
.hi { display: flex; align-items: center; gap: 10px; background: var(--soft); border-radius: 12px; padding: 6px 10px; border-left: 5px solid #bbb; }
.hi.w { border-left-color: #18b26b; } .hi.l { border-left-color: #ff4d6d; } .hi.d { border-left-color: #f0b429; }
.hi > div { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.hi small { color: var(--muted); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hi-ic { font-size: 1.4rem; }
.hi-r { text-align: right; font-weight: 800; display: flex; flex-direction: column; font-size: .85rem; }
.hi-r small { color: var(--muted); }

/* ranking */
.rank-filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 10px; color: #fff; }
.seg { display: flex; background: rgba(255,255,255,.2); border-radius: 14px; padding: 3px; gap: 2px; flex-wrap: wrap; }
.seg button { border: 0; background: none; color: #fff; font: inherit; font-weight: 700; padding: 5px 10px; border-radius: 11px; cursor: pointer; font-size: .88rem; }
.seg button.on { background: #fff; color: var(--primary); }
.rk-game { border: 0; border-radius: 12px; padding: 6px 10px; font: inherit; font-weight: 700; background: #fff; color: var(--ink); max-width: 100%; }
.rank-filters small { color: rgba(255,255,255,.85); }
.rk-mine { background: var(--yellow); color: var(--ink); border-radius: 14px; padding: 8px 14px; font-weight: 800; margin-bottom: 8px; }
.ranking li { cursor: pointer; }
.ranking .rk-name { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.ranking .rk-name .nm { font-weight: 800; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ranking .rk-name small { color: var(--muted); }

/* loja */
.shop-top { background: var(--card); border-radius: 18px; padding: 10px 14px; box-shadow: var(--shadow); display: flex; flex-direction: column; margin-bottom: 10px; }
.shop-coins { font-size: 1.3rem; font-weight: 800; }
.shop-top small { color: var(--muted); font-weight: 600; }
.shop-cats { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 6px; margin-bottom: 6px; scrollbar-width: thin; }
.shop-cats button { flex: none; border: 0; border-radius: 14px; padding: 6px 12px; font: inherit; font-weight: 700; background: rgba(255,255,255,.22); color: #fff; cursor: pointer; }
.shop-cats button.on { background: #fff; color: var(--primary); }
.shop-note { color: #fff; font-weight: 600; margin: 0 0 8px; font-size: .88rem; }
.shop-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.si { background: var(--card); border-radius: 18px; padding: 10px; box-shadow: var(--shadow); display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; }
.si.on { box-shadow: 0 0 0 3px var(--green), var(--shadow); }
.si b { font-size: .9rem; line-height: 1.15; min-height: 2.3em; display: grid; place-items: center; }
.si .btn { width: 100%; padding: 8px 6px; font-size: .9rem; }
.si-pv { height: 92px; display: grid; place-items: center; width: 100%; background: var(--soft); border-radius: 14px; }
.sp-big { font-size: 2.8rem; } .sp-big.sm { font-size: 1.8rem; letter-spacing: 2px; }
.sp-name { font-size: 1.15rem; font-weight: 800; padding: 0 6px; overflow: hidden; text-overflow: ellipsis; max-width: 100%; white-space: nowrap; }
.sp-mesa { width: 110px; height: 66px; border-radius: 10px; background: var(--c); box-shadow: inset 0 0 18px rgba(0,0,0,.45), 0 0 0 6px #5a3013; position: relative; }
.sp-mesa i { position: absolute; width: 12px; height: 12px; border-radius: 50%; background: #fff; box-shadow: 0 2px 3px rgba(0,0,0,.4); }
.sp-mesa i:nth-child(1) { left: 22px; top: 26px; } .sp-mesa i:nth-child(2) { left: 70px; top: 18px; background: #f2bf0f; } .sp-mesa i:nth-child(3) { left: 80px; top: 38px; background: #d3252b; }
.sp-tab { display: grid; grid-template-columns: repeat(3, 22px); grid-template-rows: repeat(3, 22px); border-radius: 6px; overflow: hidden; box-shadow: 0 0 0 3px #5a3a22; }
.sp-card { width: 50px; height: 72px; border-radius: 8px; border: 3px solid #fff; box-shadow: 0 3px 8px rgba(0,0,0,.3); }
.sp-faca { position: relative; width: 22px; height: 84px; }
.sp-faca i { position: absolute; left: 4px; top: 0; width: 14px; height: 48px; border-radius: 50% 50% 3px 3px / 70% 70% 3px 3px; background: linear-gradient(90deg, #fff, var(--b)); box-shadow: 0 0 6px var(--b); }
.sp-faca b { position: absolute; left: 6px; top: 50px; width: 10px; height: 32px; border-radius: 5px; background: var(--h); }

/* configurações */
.settings { display: flex; flex-direction: column; gap: 6px; }
.set-sec h4 { margin: 8px 0 8px; }
.set-sec p.muted { margin: 4px 0; font-size: .85rem; }
.theme-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.theme-opt { border: 2px solid transparent; border-radius: 14px; background: var(--soft); color: var(--ink); font: inherit; font-weight: 700; padding: 6px; display: flex; flex-direction: column; align-items: center; gap: 4px; cursor: pointer; font-size: .85rem; }
.theme-opt i { width: 100%; height: 34px; border-radius: 10px; background: var(--g); }
.theme-opt.on { border-color: var(--primary); }
.set-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 6px 0; font-weight: 700; }
.set-row input[type=range] { flex: 1; max-width: 200px; accent-color: var(--primary); }
.set-row select { border: 2px solid var(--soft); border-radius: 10px; padding: 4px 8px; font: inherit; background: var(--card); color: var(--ink); }
.switch { appearance: none; -webkit-appearance: none; width: 46px; height: 26px; border-radius: 14px; background: #cfc8e8; position: relative; cursor: pointer; transition: background .2s; flex: none; }
.switch::after { content: ''; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: left .2s; box-shadow: 0 1px 3px rgba(0,0,0,.3); }
.switch:checked { background: var(--green); }
.switch:checked::after { left: 23px; }

/* ===== temas ===== */
html.theme-oceano { --bg1: #0f5bd8; --bg2: #13a6d9; --bg3: #27d3b5; --primary: #1366d6; --primary-d: #0b4aa0; }
html.theme-floresta { --bg1: #126b3a; --bg2: #2a9d5c; --bg3: #a6c94a; --primary: #1a8a4c; --primary-d: #106636; }
html.theme-por-do-sol { --bg1: #ff6a3d; --bg2: #ff3d77; --bg3: #9b3dff; --primary: #e8455f; --primary-d: #b62b45; }
html.theme-doce { --bg1: #ff8fc7; --bg2: #b79bff; --bg3: #7fd8ff; --primary: #8e5cff; --primary-d: #6a3ad6; }
html.theme-escuro { --bg1: #120d2a; --bg2: #1d1440; --bg3: #2a1b4e; --ink: #efeaff; --muted: #a79ccf; --card: #221a42; --soft: #2f2558;
  --primary: #8b74ff; --primary-d: #5d47d6; --shadow: 0 10px 30px rgba(0, 0, 0, .45); color-scheme: dark; }
html.theme-escuro input, html.theme-escuro select, html.theme-escuro textarea { background: var(--soft); color: var(--ink); border-color: #3d3170; }
html.theme-escuro .btn.ghost { background: var(--soft); color: #cfc3ff; box-shadow: 0 4px 0 #191233; }
html.theme-escuro .me-chip .av, html.theme-escuro .pchip .av { background: #3a2f6b; }
html.theme-escuro .tb-pop-box, html.theme-escuro .qopt .who { background: var(--card); color: var(--ink); }
html.theme-escuro .shop-cats button.on, html.theme-escuro .seg button.on { background: var(--card); color: #cfc3ff; }
html.theme-escuro .rk-game { background: var(--card); color: var(--ink); }
html.theme-escuro .dd.now, html.theme-escuro .mi.ok { background: #4a3d10; color: #ffe9a6; }
html.theme-escuro .mi.ok .mi-tx small { color: #e8d48a; }
html.theme-escuro .ac.got { background: #4a3d10; color: #ffe9a6; }
html.theme-escuro .ac.got.t2 { background: #1d2f5c; color: #cfe0ff; }
html.theme-escuro .ac.got.t3 { background: linear-gradient(135deg, #5a4410, #5a1d44); color: #ffe6f5; }
html.theme-escuro .chip.on { background: #12422c; color: #8ff0bd; }
html.theme-escuro .lvb { box-shadow: 0 0 0 2px var(--card); }
html.theme-escuro .game-card .btn.ghost { color: #cfc3ff; }
html.theme-escuro .pchip.turn { background: #3a2f6b; color: #fff; }

/* espectador */
.watch-pill { display: inline-block; margin-left: 6px; font-size: .72rem; background: rgba(255,255,255,.22); border-radius: 10px; padding: 1px 7px; vertical-align: 3px; font-weight: 800; }
.watch-pill.rk { background: var(--yellow); color: var(--ink); }
#screen-game.spect .reactions { visibility: hidden; }
#screen-game.spect .chat-form { display: none; }
#screen-game.spect .game-area { pointer-events: none; }

/* amigos */
.fb { display: flex; flex-direction: column; gap: 12px; }
.fb-card { background: var(--card); border-radius: 18px; padding: 12px 14px; box-shadow: var(--shadow); }
.fb-card h4 { margin: 0 0 8px; display: flex; align-items: center; gap: 6px; }
.my-code { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.my-code b { font-size: 1.5rem; letter-spacing: 2px; color: var(--primary); }
.add-form { display: flex; gap: 8px; margin-top: 8px; }
.add-form input { flex: 1; min-width: 0; border: 2px solid var(--soft); border-radius: 12px; padding: 8px 12px; font: inherit; text-transform: uppercase; letter-spacing: 1px; background: var(--card); color: var(--ink); }
.fr-list { display: flex; flex-direction: column; gap: 8px; }
.fr-row { display: flex; align-items: center; gap: 10px; padding: 6px 0; border-top: 1px solid var(--soft); }
.fr-row:first-child { border-top: 0; }
.fr-who { flex: 1; min-width: 0; display: flex; flex-direction: column; cursor: pointer; }
.fr-who .nm { font-weight: 800; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fr-who small { color: var(--muted); font-weight: 600; font-size: .8rem; }
.fr-who small.on { color: #0b9a5c; }
.fr-acts { display: flex; gap: 6px; }
.ib { border: 0; width: 38px; height: 38px; border-radius: 12px; background: var(--soft); font-size: 1.1rem; position: relative; cursor: pointer; color: var(--ink); }
.ib.go { background: var(--primary); color: #fff; }
.ib.ok { background: var(--green); color: #fff; }
.ib .nbadge { position: absolute; top: -5px; right: -5px; background: #ff4d6d; color: #fff; font-size: .65rem; font-weight: 800; border-radius: 9px; min-width: 18px; height: 18px; display: grid; place-items: center; font-style: normal; }
.empty-note { color: var(--muted); font-weight: 600; text-align: center; padding: 8px; }

/* conversa */
.pm { display: flex; flex-direction: column; height: min(62dvh, 520px); }
.pm-list { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 6px; padding: 4px 2px; }
.pm-m { max-width: 80%; background: var(--soft); border-radius: 16px 16px 16px 4px; padding: 7px 11px; align-self: flex-start; overflow-wrap: anywhere; }
.pm-m.me { align-self: flex-end; background: var(--primary); color: #fff; border-radius: 16px 16px 4px 16px; }
.pm-m small { display: block; opacity: .7; font-size: .68rem; }
.pm-form { display: flex; gap: 8px; padding-top: 8px; }
.pm-form input { flex: 1; min-width: 0; border: 2px solid var(--soft); border-radius: 14px; padding: 9px 12px; font: inherit; background: var(--card); color: var(--ink); }

/* convite / ao vivo / escolher jogo */
.pick-games { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.pick-games button { border: 0; background: var(--soft); border-radius: 14px; padding: 8px 4px; font: inherit; font-weight: 700; font-size: .78rem; display: flex; flex-direction: column; align-items: center; gap: 2px; cursor: pointer; color: var(--ink); }
.pick-games button span { font-size: 1.6rem; }
.live-row { display: flex; align-items: center; gap: 10px; background: var(--soft); border-radius: 14px; padding: 8px 10px; margin-bottom: 8px; }
.live-row .li-ic { font-size: 1.8rem; }
.live-row div { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.live-row small { color: var(--muted); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.live-tag { font-size: .68rem; font-weight: 800; background: #ff4d6d; color: #fff; border-radius: 6px; padding: 0 5px; margin-left: 4px; }

/* barra do lobby: modo e dificuldade */
.lobby-tools { display: flex; flex-direction: column; gap: 8px; margin-bottom: 12px; }
.lobby-tools:empty { display: none; }
.tools-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.lvl-pick { display: flex; align-items: center; gap: 4px; background: rgba(255,255,255,.2); border-radius: 14px; padding: 3px 4px 3px 10px; color: #fff; font-weight: 700; }
.lvl-pick select { border: 0; border-radius: 11px; padding: 4px 8px; font: inherit; font-weight: 700; background: #fff; color: var(--ink); }
html.theme-escuro .lvl-pick select { background: var(--card); color: var(--ink); }
.gc-actions.three { grid-template-columns: 1fr 1fr auto; }
.gc-actions .btn.tr { padding-left: 12px; padding-right: 12px; }
.lvl-row { display: flex; align-items: center; justify-content: center; gap: 8px; color: #fff; font-weight: 700; flex-wrap: wrap; }
.seg.mini button { padding: 4px 8px; font-size: .8rem; }

/* resultado */
.res-extra { display: flex; flex-direction: column; gap: 4px; align-items: center; margin: 6px 0 4px; }
.res-extra:empty { display: none; }
.res-series { font-weight: 700; color: var(--muted); }
.res-series .me { color: var(--primary); }
.res-elo { font-weight: 800; border-radius: 10px; padding: 2px 10px; }
.res-elo.up { background: #dff7ea; color: #0b7a4b; } .res-elo.down { background: #ffe3e8; color: #b0213b; }
.res-xp { font-weight: 800; color: var(--primary); font-size: .9rem; }
.res-tour { font-weight: 700; color: var(--muted); font-size: .9rem; }

/* torneios */
.tours { display: flex; flex-direction: column; gap: 10px; }
.tour { background: var(--soft); border-radius: 16px; padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; }
.tour.jogando { box-shadow: 0 0 0 2px #ff4d6d; }
.tour-h { display: flex; align-items: center; gap: 10px; }
.tour-h > div { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.tour-h small { color: var(--muted); font-weight: 600; }
.tour-ic { font-size: 2rem; }
.tour-st { font-weight: 800; font-size: .85rem; white-space: nowrap; }
.tour-champ { font-weight: 800; background: #fff3c4; color: #5a4300; border-radius: 10px; padding: 4px 10px; }
.brk { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; }
.brk-col { display: flex; flex-direction: column; gap: 6px; justify-content: space-around; min-width: 150px; }
.brk-t { font-size: .78rem; color: var(--muted); text-align: center; }
.brk-m { background: var(--card); border-radius: 10px; padding: 4px 6px; display: flex; flex-direction: column; gap: 2px; box-shadow: 0 1px 4px rgba(0,0,0,.08); }
.brk-m.live { box-shadow: 0 0 0 2px #ff4d6d; }
.brk-p { display: flex; align-items: center; gap: 4px; font-size: .8rem; font-weight: 700; }
.brk-p .brk-n { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.brk-p.w { color: #0b8a54; } .brk-p.l { opacity: .45; text-decoration: line-through; }
.brk-p.me .brk-n { color: var(--primary); }
.brk-m small { color: var(--muted); font-size: .68rem; }
.brk-watch { border: 0; background: #ff4d6d; color: #fff; border-radius: 8px; font: inherit; font-size: .72rem; font-weight: 800; padding: 1px 6px; cursor: pointer; }

/* desafio do dia */
.dch { display: flex; flex-direction: column; gap: 8px; }
.dch-top { display: flex; gap: 12px; align-items: center; }
.dch-top > div { display: flex; flex-direction: column; }
.dch-top small { color: var(--muted); font-weight: 600; }
.dch-ic { font-size: 2.6rem; }
.dch h4 { margin: 6px 0 0; }
.dch-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.dch-list li { display: grid; grid-template-columns: 40px 1fr auto; gap: 6px; background: var(--soft); border-radius: 10px; padding: 5px 10px; font-weight: 700; }

/* blocos do topo numa faixa que rola para o lado (economiza espaço no celular) */
.hub { display: flex; overflow-x: auto; gap: 8px; padding: 2px 2px 8px; margin: 0 -2px 6px; scroll-snap-type: x proximity; scrollbar-width: none; }
.hub::-webkit-scrollbar { display: none; }
.hub-tile { flex: 0 0 auto; width: 156px; min-height: 54px; padding: 8px 10px; scroll-snap-align: start; }
.hub-tile .ht-ic { font-size: 1.5rem; }
.hub-tile b { font-size: .9rem; white-space: nowrap; }
.hub-tile small { white-space: nowrap; font-size: .74rem; }
@media (min-width: 760px) { .hub { flex-wrap: wrap; overflow: visible; } .hub-tile { width: auto; flex: 1 1 140px; } }

/* lobby: seções, favoritos, novos, busca */
.game-sections .gs-title:first-child { margin-top: 4px; }
.gs-title { font-size: 1.15rem; margin: 18px 0 8px; }
.gs-empty { color: #fff; font-weight: 700; text-align: center; padding: 20px; }
.g-search { flex: 1; min-width: 160px; border: 0; border-radius: 14px; padding: 9px 14px; font: inherit; font-weight: 600; background: rgba(255,255,255,.92); color: var(--ink); }
html.theme-escuro .g-search { background: var(--card); }
.gc-fav { position: absolute; top: 10px; right: 48px; width: 32px; height: 32px; border-radius: 50%; border: 0; background: var(--soft); color: #c9a300; font-size: 1.15rem; cursor: pointer; line-height: 1; }
.gc-fav.on { background: #fff3c4; color: #e2a400; }
.game-card h3 { padding-right: 76px; }
.gc-new { display: inline-block; margin-left: 6px; font-size: .62rem; font-weight: 800; background: #ff4d6d; color: #fff; border-radius: 6px; padding: 1px 5px; vertical-align: 3px; }
.gc-hot { margin-left: 8px; color: #e8455f; font-weight: 800; }
@media (max-width: 600px) { .hero { padding: 12px; gap: 8px; } .hero h1 { font-size: 1.3rem; } .hero p { display: none; } }

/* avisos do administrador e eventos */
#lobby-notice { display: flex; flex-direction: column; gap: 8px; margin-bottom: 10px; }
#lobby-notice:empty { display: none; }
.notice { display: flex; align-items: center; gap: 10px; border-radius: 16px; padding: 8px 12px; font-weight: 600; box-shadow: var(--shadow); background: #fff3c4; color: #4a3b00; }
.notice p { margin: 0; flex: 1; line-height: 1.3; }
.notice .n-ic { font-size: 1.4rem; }
.notice .n-x { border: 0; background: rgba(0,0,0,.08); border-radius: 50%; width: 28px; height: 28px; cursor: pointer; color: inherit; flex: none; }
.notice.c-azul { background: #dcebff; color: #12325e; } .notice.c-verde { background: #dff7ea; color: #0b4d31; }
.notice.c-vermelho { background: #ffe0e5; color: #6b0f1f; } .notice.c-roxo { background: #ece5ff; color: #34197a; }
.notice.c-evento { background: linear-gradient(90deg, #ffd76a, #ff9fd2); color: #3a1630; }
/* denunciar mensagem */
.msg { position: relative; }
.msg-rep { border: 0; background: none; color: var(--muted); opacity: .45; cursor: pointer; font-size: .85rem; align-self: flex-start; padding: 2px 4px; margin-left: auto; }
.msg-rep:hover, .msg-rep:focus-visible { opacity: 1; color: #e8455f; }
