/* MU GAME Hard, site oficial: peças que ligam o visual aprovado ao site de verdade
   (janelas do Semantic usadas pelo default.js, carregando dos templates, aviso de processando, login). */

/* ---------- carregando e erro dos templates ---------- */
.tpl-loading { display: flex; align-items: center; gap: 10px; padding: 16px; font-size: 13px; color: var(--ink-3); }
.tpl-loading::before { content: ""; width: 14px; height: 14px; border-radius: 50%; border: 2px solid rgba(20, 26, 32, .15); border-top-color: var(--red); animation: hdGira .8s linear infinite; }
.mod-dark .tpl-loading { color: #8f9ba6; }
.mod-dark .tpl-loading::before { border-color: rgba(255, 255, 255, .15); border-top-color: var(--red); }
.tpl-error { margin: 12px 16px; padding: 9px 12px; font-size: 13px; font-weight: 600; color: var(--red-2); background: var(--red-soft); border-left: 3px solid var(--red); }
@keyframes hdGira { to { transform: rotate(360deg); } }
.hd-vazio { padding: 22px 16px; font-size: 13.5px; color: var(--ink-3); text-align: center; }

/* ---------- login do menu do lado ---------- */
.mod-dark form#login { padding: 14px; }
.mod-dark .mnu-error pre, .mnu-error pre { margin: 0; font: inherit; white-space: pre-wrap; }
.lg-safe { margin: 12px 0 0; font-size: 11px; line-height: 1.45; color: #6f7b86; }
.lg-safe a { color: #93a0ab; text-decoration: underline; text-underline-offset: 2px; }
.fld.error input, .fld2.error input { border-color: var(--red); }
.acc-ini { display: grid; place-items: center; width: 42px; height: 42px; font: 600 20px var(--f-disp); color: #fff; background: var(--ink-soft); clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px); }
.acc-id span.acc-free { color: #93a0ab; }
.acc-id em { font-style: normal; font-weight: 400; color: #c9b27a; }
.acc-foot a#logout { color: #ff8a9a; }
.btn.is-loading, .btn[disabled] { opacity: .7; cursor: progress; }

/* ---------- jogadores online da apresentação ---------- */
.hero-on .ho-off { font: 600 34px/1 var(--f-disp); letter-spacing: .04em; color: #ffb3bf; }

/* ---------- janelas (Semantic UI modal com o visual do Hard) ---------- */
.ui.dimmer { background: rgba(10, 14, 18, .66); }
.ui.modal { border-radius: 0; box-shadow: 0 30px 70px -20px rgba(0, 0, 0, .6); background: var(--plate); color: var(--ink); font-family: var(--f-body); }
.ui.modal > .header { padding: 15px 20px; border-bottom: 1px solid var(--line); border-radius: 0 !important; background: var(--plate);
  font: 600 19px/1.2 var(--f-disp) !important; letter-spacing: .05em; text-transform: uppercase; color: var(--ink); }
.ui.modal > .header::before { content: ""; display: block; width: 34px; height: 3px; margin-bottom: 9px; background: var(--red); }
.ui.modal > .content { padding: 16px 20px; background: var(--plate); font-size: 14px; line-height: 1.55; }
.ui.modal > .actions { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 20px 16px; border-top: 1px solid var(--line); border-radius: 0 !important; background: var(--plate-2); text-align: right; }
.ui.modal > .actions .btn { margin: 0; }
.ui.tiny.modal { width: 460px; margin: 0; }
.ui.small.modal { width: 560px; margin: 0; }
.ui.modal .hm-lead { margin: 0 0 14px; color: var(--ink-2); }
.ui.modal form { display: grid; gap: 12px; }
.ui.modal .mnu-error, .ui.modal [data-error] { display: block; padding: 8px 11px; font-size: 13px; font-weight: 600; color: var(--red-2); background: var(--red-soft); border-left: 3px solid var(--red); }
.ui.modal .mnu-error:empty, .ui.modal .mnu-error[style*="none"] { display: none; }
.ui.modal [data-error].hidden, .ui.modal .hidden[data-error] { display: none; }
.ui.modal [data-error] pre, .ui.modal .mnu-error pre { margin: 0; font: inherit; white-space: pre-wrap; }
.ui.modal .ui.button { display: inline-flex; align-items: center; justify-content: center; height: 38px; padding: 0 18px; border: 0; border-radius: 0; cursor: pointer;
  font: 600 14px var(--f-disp); letter-spacing: .08em; text-transform: uppercase; background: var(--plate); color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ink); }
.ui.modal .ui.button.primary, .ui.modal .ui.button.hd-ok { background: var(--red); color: #fff; box-shadow: none; }
.ui.modal .ui.button.loading { opacity: .7; pointer-events: none; }
.ui.modal select { width: 100%; height: 40px; padding: 0 10px; border: 1px solid var(--line-2); background: var(--plate); font: 500 14px var(--f-body); color: var(--ink); }
.ui.modal .hm-rows { display: grid; gap: 6px; margin: 10px 0; }
.ui.modal .hm-rows > div { padding: 7px 10px; background: var(--plate-2); border-left: 3px solid var(--line-2); font-size: 13.5px; }
.ui.modal .hm-k { margin: 12px 0 4px; font: 600 12px var(--f-disp); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); }

/* ---------- tela de processando (api.js) ---------- */
.wait-ov { position: fixed; inset: 0; z-index: 2147482000; display: none; place-items: center; background: rgba(10, 14, 18, .62); }
.wait-ov.on { display: grid; }
.wait-box { display: grid; justify-items: center; gap: 8px; width: 340px; padding: 24px 26px; text-align: center; background: var(--ink); color: #fff; border-top: 3px solid var(--red); }
.wait-box strong { font: 600 20px var(--f-disp); letter-spacing: .05em; text-transform: uppercase; }
.wait-box p { margin: 0; font-size: 13px; color: #c3ccd4; }
.wait-box small { font-size: 12px; color: #8f9ba6; }
.wait-spin { width: 40px; height: 40px; border-radius: 50%; border: 3px solid rgba(255, 255, 255, .15); border-top-color: var(--red); animation: hdGira .8s linear infinite; }
html.wait-lock { overflow: hidden; }

/* ---------- avisos rápidos ---------- */
.hd-aviso { margin: 0 0 14px; padding: 10px 13px; font-size: 13.5px; color: var(--ink-2); background: var(--plate); border-left: 3px solid var(--red); }
.hd-aviso.ok { border-left-color: var(--ok); }
.hd-aviso a { color: var(--red); font-weight: 600; }

@media (prefers-reduced-motion: reduce) and (max-width: 0px) { .tpl-loading::before, .wait-spin { animation: none; } }

/* ---------- rankings com dados de verdade ---------- */
.rk-perfil { color: inherit; text-decoration: none; }
.rk-perfil:hover { text-decoration: underline; text-underline-offset: 3px; }
.rk .rk-wait, .hb-ls .hb-vazio { display: block; padding: 10px 2px; font-size: 12.5px; color: var(--ink-3); background: none; }
.hb-ls .hb-vazio { color: #8f9ba6; }
.rk-ini { display: grid; place-items: center; width: 28px; height: 28px; font: 600 14px var(--f-disp); color: #fff; background: #26313b; }
.rk-ini .i { width: 22px; height: 22px; }
.pod .av .rk-ini { width: 100%; height: 100%; font-size: 24px; }
.rk-table .cls .rk-ini { width: 22px; height: 22px; font-size: 12px; }
.rk-live td:nth-child(3) { font: 600 16px var(--f-disp); }
.rk-live td:nth-child(4) { font: inherit; }
.cp-off { font-weight: 400; color: #8f9ba6; }
.dl-go .dl-btn small { margin-left: 6px; font: 600 12px var(--f-body); opacity: .75; }
.dl-go .dl-d { margin-top: -4px; }
.js-ar-cdbox[hidden] { display: none !important; }
.hd-gate .note-pad a { color: var(--red); font-weight: 600; }
.xch-h { margin: 18px 0 10px; font: 600 18px var(--f-disp); letter-spacing: .08em; text-transform: uppercase; color: var(--ink); }
.xch-h:first-of-type { margin-top: 4px; }
.xch:empty::before { content: "Nenhuma troca disponível agora."; display: block; padding: 14px; font-size: 13px; color: var(--ink-3); }
.xc-row > div { display: grid; gap: 3px; }
.btn.loading { opacity: .7; pointer-events: none; }
.ch-act a.btn { text-decoration: none; }
/* conteúdo que vem de template dentro do <main>: mesmo espaçamento entre os blocos */
.main > .tw > * + * { margin-top: 18px; }
.main > .tw > .ui.modal { margin-top: 0; }
.bk-a .btn[disabled] { opacity: .35; cursor: not-allowed; }
/* campos dentro das janelas (a janela sai do <main>: precisa do estilo em todas as páginas) */
.ui.modal .fld2 { display: grid; gap: 5px; }
.ui.modal .fld2 > span:first-child { font: 600 12.5px var(--f-body); color: var(--ink-2); }
.ui.modal .fld2 input { width: 100%; height: 42px; padding: 0 12px; border: 1px solid var(--line-2); border-radius: 0; background: var(--plate); font: 500 14px var(--f-body); color: var(--ink); }
.ui.modal .fld2 input:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 3px rgba(20, 26, 32, .08); }
.ui.modal .fld2.error input, .ui.modal .fld2.bad input { border-color: var(--red); }
.btn[hidden], button[hidden] { display: none !important; }
.dl-go { min-width: 0; }
.dl-go .dl-btn { width: 100%; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }

/* ---------- aviso de prêmio no Baú de prêmios (31/10) ---------- */
.pz-aviso { position: fixed; z-index: 9000; right: 18px; bottom: 18px; width: min(340px, calc(100vw - 32px)); padding: 16px 18px 18px;
  background: #151b21; color: #e8edf1; border-left: 3px solid var(--red, #e0142f);
  clip-path: polygon(0 0, calc(100% - 12px) 0, 100% 12px, 100% 100%, 0 100%);
  box-shadow: 0 18px 40px rgba(0, 0, 0, .45); animation: pzEntra .45s cubic-bezier(.2, .9, .3, 1.1); font-family: var(--f-body, sans-serif); }
@keyframes pzEntra { from { transform: translateY(24px); opacity: 0; } }
.pz-t { display: flex; align-items: center; gap: 8px; margin: 0 26px 8px 0; font: 600 19px/1.2 var(--f-disp, sans-serif); letter-spacing: .02em; color: #fff; }
.pz-t .i { width: 20px; height: 20px; flex: none; color: #ff5a6e; }
.pz-l { list-style: none; margin: 0 0 10px; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.pz-l li { padding: 4px 9px; background: rgba(255, 255, 255, .08); font-size: 13px; }
.pz-l b { color: #fff; }
.pz-c { margin: 0 0 12px; font-size: 12.5px; line-height: 1.45; color: #a9b4be; }
.pz-bt { display: block; padding: 10px 14px; text-align: center; text-decoration: none; font: 600 15px var(--f-disp, sans-serif); letter-spacing: .04em;
  color: #fff; background: var(--red, #e0142f); clip-path: polygon(0 0, calc(100% - 8px) 0, 100% 8px, 100% 100%, 0 100%); }
.pz-bt:hover, .pz-bt:focus-visible { filter: brightness(1.1); color: #fff; }
.pz-x { position: absolute; top: 10px; right: 10px; width: 28px; height: 28px; display: grid; place-items: center; padding: 0; border: 0; background: rgba(255, 255, 255, .08); color: #c3ccd4; cursor: pointer; }
.pz-x .i { width: 14px; height: 14px; }
.pz-x:focus-visible, .pz-bt:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { .pz-aviso { animation: none; } }

/* ---------- notícia aberta (noticias.html?n=id, 31/10) ---------- */
.na-art { padding: 20px 22px 22px; margin-bottom: 18px; }
.na-art .na-head { display: flex; align-items: center; gap: 10px; margin: 0 0 8px; }
.na-art .na-head time { font: 400 12px var(--f-mono); color: var(--ink-2); }
.na-art h2 { margin: 0 0 12px; font: 600 26px/1.15 var(--f-disp); letter-spacing: .01em; color: var(--ink); }
.na-art p { max-width: 70ch; margin: 0 0 10px; font-size: 14.5px; line-height: 1.6; color: var(--ink-2); }
.na-art p b { color: var(--ink); }
.na-art .na-bt { display: inline-flex; align-items: center; gap: 6px; margin-top: 6px; }
.news li.is-open a { background: var(--plate-2); }
.news li.is-open a::before { background: var(--red); top: 0; bottom: 0; }
@media (max-width: 560px) { .na-art { padding: 16px; } .na-art h2 { font-size: 22px; } }
