/* v145 · "Conexão perdida" por cima de tudo */
.nl { position: fixed; inset: 0; z-index: 2147483647; display: flex; align-items: center; justify-content: center; background: rgba(8, 4, 20, .62); backdrop-filter: blur(2px); touch-action: none; }
.nl.hidden { display: none; }
.nl-card { width: min(72vw, 560px); background: #1d2022; color: #e8eaed; border-radius: calc(28 * var(--u, 1px)); padding: calc(26 * var(--u, 1px)) calc(28 * var(--u, 1px)) calc(18 * var(--u, 1px)); font-family: Roboto, system-ui, sans-serif; box-shadow: 0 10px 40px rgba(0, 0, 0, .6); }
.nl-card h2 { margin: 0 0 calc(14 * var(--u, 1px)); font-size: calc(24 * var(--u, 1px)); font-weight: 500; }
.nl-card p { margin: 0 0 calc(40 * var(--u, 1px)); font-size: calc(19 * var(--u, 1px)); color: #c8ccd0; }
.nl-b { background: none; border: 0; color: #9fd8ff; font-size: calc(19 * var(--u, 1px)); font-weight: 500; padding: calc(8 * var(--u, 1px)) 0; cursor: pointer; font-family: inherit; }
.nl-b:disabled { opacity: .6; }
body.net-lost { overflow: hidden; }
/* v146 · botões de escolha no carregamento */
.sg2 .sg2-ch { display: flex; gap: 1.6vh; margin-top: 1.6vh; }
.sg2 .sg2-b { flex: 1; border: 1px solid rgba(27, 229, 255, .5); border-radius: 12px; padding: 1.4vh 1vh; background: rgba(8, 20, 44, .9); color: #fff; font: 800 clamp(11px, 2.6vh, 16px) Rajdhani, system-ui, sans-serif; letter-spacing: .08em; cursor: pointer; }
.sg2 .sg2-b small { display: block; margin-top: .4vh; font: 500 clamp(8px, 1.8vh, 11px) system-ui, sans-serif; letter-spacing: 0; color: #9bb4dc; }
.sg2 .sg2-b.on { background: linear-gradient(180deg, #1be5ff, #0b8fb8); color: #021018; border-color: #8ff3ff; }
.sg2 .sg2-b.on small { color: #07323f; }
/* v146 · menu do modo offline */
.off { position: fixed; inset: 0; z-index: 8000; background: #03060b; display: flex; align-items: center; justify-content: center; color: #fff; font-family: Rajdhani, system-ui, sans-serif; overflow: hidden; }
.off-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: blur(6px) brightness(.35) saturate(.8); }
.off-vig { position: absolute; inset: 0; background: radial-gradient(ellipse at center, transparent 30%, rgba(0, 0, 0, .7)); }
.off-c { position: relative; width: min(86vw, 640px); text-align: center; }
.off-c small { color: #ffd27c; letter-spacing: .3em; font-weight: 700; font-size: calc(12 * var(--u, 1px)); }
.off-c h1 { margin: calc(4 * var(--u, 1px)) 0 calc(10 * var(--u, 1px)); font-size: calc(40 * var(--u, 1px)); letter-spacing: .06em; } .off-c h1 b { color: #1be5ff; }
.off-warn { background: rgba(255, 210, 124, .1); border: 1px solid rgba(255, 210, 124, .4); color: #ffe3a8; border-radius: 12px; padding: calc(9 * var(--u, 1px)) calc(14 * var(--u, 1px)); font-size: calc(14 * var(--u, 1px)); line-height: 1.35; }
.off-g { display: flex; gap: calc(14 * var(--u, 1px)); margin: calc(16 * var(--u, 1px)) 0; }
.off-card { flex: 1; border: 1px solid rgba(27, 229, 255, .5); border-radius: 14px; padding: calc(18 * var(--u, 1px)) calc(10 * var(--u, 1px)); background: linear-gradient(180deg, rgba(14, 30, 62, .92), rgba(6, 12, 28, .95)); color: #fff; cursor: pointer; font-family: inherit; }
.off-card b { display: block; font-size: calc(24 * var(--u, 1px)); letter-spacing: .08em; color: #1be5ff; } .off-card span { display: block; margin-top: calc(6 * var(--u, 1px)); font-size: calc(13 * var(--u, 1px)); color: #b9c9e6; }
.off-on { background: linear-gradient(180deg, #ffd45c, #f0a500); color: #1a1000; border: 0; border-radius: 12px; padding: calc(12 * var(--u, 1px)) calc(26 * var(--u, 1px)); font: 800 calc(17 * var(--u, 1px)) Rajdhani, system-ui, sans-serif; letter-spacing: .08em; cursor: pointer; }
.off-msg { min-height: 1.4em; margin-top: calc(10 * var(--u, 1px)); color: #ff9d9d; font-size: calc(13 * var(--u, 1px)); }
body.offline-mode #dlBar, body.offline-mode #dlSheet { display: none !important; }
/* v146 · painel de escolha (sem conexão) — sobrepõe o estilo do carregamento */
.sg2.choice .sg2-panel { position: absolute; left: 50%; bottom: 5%; transform: translateX(-50%); width: min(90vw, 600px); height: auto; overflow: visible; padding: 14px 16px; }
.sg2.choice .sg2-st { font-weight: 800; letter-spacing: .12em; color: #ff9d9d; margin-bottom: 4px; }
.sg2.choice .sg2-sub { text-align: left; }
.sg2.choice .sg2-ch { position: static; display: flex; gap: 12px; margin-top: 12px; }
.sg2.choice .sg2-b { position: static; flex: 1; display: block; min-height: 52px; pointer-events: auto; }

.sg2 .sg2-foot { font-size: calc(13 * var(--u, 1px)) !important; opacity: .95 !important; }
/* v151 · o aviso antigo "Sem conexão com o servidor (modo offline)" cobria o painel de modos de preto: a conexão agora é tratada pela tela de carregamento */
#mcOnline, #mcOnline.off { display: none !important; }

/* v153 · aviso "Conexão restabelecida" (mesma tela do "Sem conexão") e selo do modo offline */
#netBack.sg2 { position: fixed; inset: 0; z-index: 2147483000; background: #03060b; overflow: hidden; display: flex; align-items: center; justify-content: center; cursor: default; }
#netBack.sg2 .sg2-st { color: #7cffb2 !important; }
#offBadge { position: fixed; z-index: 40; left: 50%; bottom: calc(env(safe-area-inset-bottom, 0px) + 6px); transform: translateX(-50%); display: flex; align-items: center; gap: calc(7 * var(--u, 1px)); padding: calc(3 * var(--u, 1px)) calc(12 * var(--u, 1px)); border-radius: 999px; border: 1px solid rgba(255, 210, 124, .55); background: rgba(20, 14, 4, .72); color: #ffd27c; font: 800 calc(11 * var(--u, 1px)) Rajdhani, system-ui, sans-serif; letter-spacing: .14em; cursor: pointer; white-space: nowrap; }
#offBadge i { width: calc(7 * var(--u, 1px)); height: calc(7 * var(--u, 1px)); border-radius: 50%; background: #ffb020; box-shadow: 0 0 8px #ffb020; }
#offBadge small { font: 500 calc(9 * var(--u, 1px)) system-ui, sans-serif; letter-spacing: 0; color: #d8c18a; }
body.world3d-open #offBadge { display: none; }
#offToast { position: fixed; z-index: 2147483100; left: 50%; top: 14%; transform: translate(-50%, -8px); opacity: 0; pointer-events: none; max-width: 86vw; text-align: center; background: rgba(10, 16, 34, .95); border: 1px solid rgba(255, 210, 124, .6); color: #ffe3a8; padding: calc(10 * var(--u, 1px)) calc(18 * var(--u, 1px)); border-radius: 12px; font: 700 calc(14 * var(--u, 1px)) Rajdhani, system-ui, sans-serif; transition: opacity .2s, transform .2s; }
#offToast.on { opacity: 1; transform: translate(-50%, 0); }
