/* ScreenShared — sistema visual (do atlas sheetui2.png) */

:root {
  /* ---- tema padrao: preto e grafite, sem cor viva. Os outros temas ficam no fim deste arquivo. ---- */
  --bg: #0a0a0c;
  --bg-2: #0e0e11;
  --inset: #0c0c0f;      /* campos e trilhos afundados */
  --deep: #050506;       /* atras de video e nas sobreposicoes */
  --surface: #131316;
  --surface-2: #19191d;
  --surface-3: #202025;
  --line: #222227;
  --line-2: #2e2e35;
  --line-3: #3e3e47;
  --track: #25252b;
  --track-2: #303038;

  --text: #e9e9ee;
  --text-2: #a6a6b0;
  --text-3: #6c6c77;
  --title: #ffffff;

  /* destaque: no tema preto e' um cinza claro; conta premium pode trocar por uma cor */
  --accent: #dcdce4;
  --accent-2: #f1f1f6;
  --accent-3: #c3c3cd;
  --on-accent: #0b0b0d;
  --accent-text: #d2d2dc;
  --accent-tint: rgba(255, 255, 255, .045);
  --accent-soft: rgba(255, 255, 255, .085);
  --accent-line: rgba(255, 255, 255, .17);
  --accent-ring: rgba(255, 255, 255, .16);
  --accent-shadow: rgba(0, 0, 0, .5);
  --link: #b9c2e6;

  --primary: var(--accent);
  --primary-2: var(--accent-2);
  --primary-3: var(--accent-3);
  --blue: var(--accent-3);
  --blue-2: var(--link);
  --magenta: #b06ac2;
  --online: #3fcf7f;
  --ok: #2c9c5c;
  --ok-text: #86e0ac;
  --busy: #e0a030;
  --busy-text: #edc47c;
  --danger: #d8394c;
  --danger-text: #f0909b;
  --info: #5b7fd6;
  --line-glow: var(--accent-line);

  --grad: linear-gradient(135deg, var(--accent-2) 0%, var(--accent) 55%, var(--accent-3) 100%);
  --grad-soft: linear-gradient(135deg, var(--accent-soft), var(--accent-tint));

  /* cores dos avatares de iniciais */
  --av-1: linear-gradient(135deg, #5a5d6e, #3d3f4c);
  --av-2: linear-gradient(135deg, #6b5a6e, #46394a);
  --av-3: linear-gradient(135deg, #51606f, #37424d);
  --av-4: linear-gradient(135deg, #4f6659, #36473d);
  --av-5: linear-gradient(135deg, #73614c, #4d4033);
  --av-6: linear-gradient(135deg, #5a5574, #3c3950);

  --radius: 12px;
  --radius-sm: 9px;
  --shadow: 0 18px 50px rgba(0, 0, 0, .55);
  --font: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-display: "Poppins", var(--font);
  --mono: ui-monospace, "Cascadia Code", Consolas, monospace;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html, body {
  margin: 0;
  height: 100%;
  background: var(--bg);
  color: var(--text);
  font: 14px/1.5 var(--font);
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--accent-soft); }

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: 10px; border: 3px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-track { background: transparent; }

a { color: var(--blue-2); }

/* ---------------------------------------------------------------- icones */

.ic { width: 18px; height: 18px; flex: 0 0 auto; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.ic.lg { width: 22px; height: 22px; }
.ic.xl { width: 30px; height: 30px; }

/* ---------------------------------------------------------------- marca */

.brand { display: inline-flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 700; font-size: 16px; letter-spacing: -.01em; color: #fff; text-decoration: none; }
.brand .logo { width: 28px; height: 28px; }
.brand b { font-weight: 700; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ---------------------------------------------------------------- botoes */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  font: 600 13.5px/1 var(--font); color: var(--text);
  background: var(--surface-2); border: 1px solid var(--line-2); border-radius: var(--radius-sm);
  padding: 11px 16px; cursor: pointer; white-space: nowrap;
  transition: background .14s, border-color .14s, box-shadow .14s, transform .06s, color .14s;
}
.btn:hover:not(:disabled) { background: var(--surface-3); border-color: var(--line-3); }
.btn:active:not(:disabled) { transform: translateY(1px); }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn:focus-visible, .ibtn:focus-visible, .field:focus-visible { outline: 2px solid var(--primary-2); outline-offset: 2px; }

.btn.primary { background: var(--grad); border-color: transparent; color: var(--on-accent); box-shadow: 0 8px 26px var(--accent-shadow), inset 0 1px 0 rgba(255,255,255,.18); }
.btn.primary:hover:not(:disabled) { filter: brightness(1.08); box-shadow: 0 10px 32px var(--accent-shadow), inset 0 1px 0 rgba(255,255,255,.2); }
.btn.ghost { background: transparent; border-color: var(--line-2); }
.btn.ghost:hover:not(:disabled) { background: var(--accent-tint); border-color: var(--primary); }
.btn.danger { background: var(--danger); border-color: transparent; color: #fff; }
.btn.danger:hover:not(:disabled) { filter: brightness(1.1); background: var(--danger); }
.btn.sm { padding: 7px 11px; font-size: 12.5px; border-radius: 8px; gap: 7px; }
.btn.block { width: 100%; }

/* botao quadrado de icone (a fileira de controles do atlas) */
.ibtn {
  position: relative; display: inline-grid; place-items: center;
  width: 44px; height: 44px; border-radius: 11px; cursor: pointer;
  color: var(--text); background: color-mix(in srgb, var(--surface-2) 82%, transparent); border: 1px solid var(--line-2);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  transition: background .14s, border-color .14s, color .14s;
}
.ibtn:hover { background: var(--surface-3); border-color: var(--line-3); }
.ibtn.on { background: var(--grad); border-color: transparent; color: var(--on-accent); box-shadow: 0 6px 22px var(--accent-shadow); }
.ibtn.sm { width: 34px; height: 34px; border-radius: 9px; }
.ibtn.sm .ic { width: 16px; height: 16px; }
.ibtn .badge { position: absolute; top: -6px; right: -6px; }

.badge {
  min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  font: 700 10.5px/18px var(--font); text-align: center; color: #fff;
  background: var(--magenta); box-shadow: 0 0 0 2px var(--bg);
}

/* ---------------------------------------------------------------- campos */

.field {
  width: 100%; font: 14px var(--font); color: var(--text);
  background: var(--bg-2); border: 1px solid var(--line-2); border-radius: var(--radius-sm);
  padding: 11px 13px; transition: border-color .14s, box-shadow .14s;
}
.field::placeholder { color: var(--text-3); }
.field:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--accent-ring); }
select.field { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--text-2) 50%), linear-gradient(135deg, var(--text-2) 50%, transparent 50%); background-position: calc(100% - 17px) 50%, calc(100% - 12px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 32px; }
label.lbl { display: block; font-size: 12px; font-weight: 600; color: var(--text-2); margin: 0 0 7px; }
.hint { font-size: 12px; color: var(--text-3); margin-top: 6px; }

/* campo com botao de copiar (cartao "Convidar amigo") */
.copyrow { display: flex; align-items: center; gap: 6px; background: var(--bg-2); border: 1px solid var(--line-2); border-radius: var(--radius-sm); padding: 4px 4px 4px 13px; min-width: 0; }
.copyrow code { flex: 1; min-width: 0; font: 13px var(--mono); color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.copyrow .ibtn { width: 34px; height: 34px; background: transparent; border-color: transparent; }
.copyrow .ibtn:hover { background: var(--surface-3); }

/* range com trilho preenchido */
input[type="range"] { -webkit-appearance: none; appearance: none; height: 4px; border-radius: 4px; background: linear-gradient(90deg, var(--primary-2) var(--p, 100%), var(--track-2) var(--p, 100%)); cursor: pointer; }
input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 14px; height: 14px; border-radius: 50%; background: #fff; border: 3px solid var(--primary); box-shadow: 0 0 0 3px var(--accent-ring); }
input[type="range"]::-moz-range-thumb { width: 10px; height: 10px; border-radius: 50%; background: #fff; border: 3px solid var(--primary); }

/* interruptor */
.switch { position: relative; width: 42px; height: 24px; flex: 0 0 auto; }
.switch input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; z-index: 1; }
.switch span { position: absolute; inset: 0; border-radius: 12px; background: var(--track-2); transition: background .15s; }
.switch span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform .15s; }
.switch input:checked + span { background: var(--grad); }
.switch input:checked + span::after { transform: translateX(18px); }

/* ---------------------------------------------------------------- cartoes */

.card {
  background: linear-gradient(180deg, color-mix(in srgb, var(--surface-3) 55%, transparent), color-mix(in srgb, var(--surface) 75%, transparent));
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px;
}
.card.glow { border-color: var(--accent-line); box-shadow: 0 0 0 1px var(--accent-ring), 0 20px 60px var(--accent-ring); }
.card h3 { margin: 0 0 4px; font: 600 15px/1.3 var(--font-display); color: #fff; }
.card .sub { margin: 0 0 14px; font-size: 12.5px; color: var(--text-2); }

/* pilula de status (Online / Ocupado / Offline do atlas) */
.pill { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px 6px 10px; border-radius: 999px; font-size: 12.5px; font-weight: 600; color: var(--text); background: color-mix(in srgb, var(--surface-2) 80%, transparent); border: 1px solid var(--line-2); white-space: nowrap; }
.dot { width: 9px; height: 9px; border-radius: 50%; background: var(--text-3); flex: 0 0 auto; }
.dot.on { background: var(--online); box-shadow: 0 0 0 3px color-mix(in srgb, var(--online) 16%, transparent), 0 0 12px color-mix(in srgb, var(--online) 55%, transparent); }
.dot.warn { background: var(--busy); box-shadow: 0 0 0 3px color-mix(in srgb, var(--busy) 16%, transparent); }
.dot.off { background: var(--text-3); }
.dot.live { background: var(--danger); box-shadow: 0 0 0 3px color-mix(in srgb, var(--danger) 20%, transparent); animation: pulse 1.6s ease-in-out infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 6px transparent; } }

/* avatar de iniciais */
.av { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; flex: 0 0 auto; font: 700 13px var(--font); color: #fff; background: var(--av, var(--av-1)); position: relative; }
.av.sm { width: 26px; height: 26px; font-size: 11px; }
.av .st { position: absolute; right: -1px; bottom: -1px; width: 10px; height: 10px; border-radius: 50%; background: var(--online); box-shadow: 0 0 0 2px var(--surface); }

/* ---------------------------------------------------------------- avisos */

.toasts { position: fixed; z-index: 50; right: 16px; top: 16px; display: flex; flex-direction: column; gap: 10px; width: min(340px, calc(100vw - 32px)); pointer-events: none; }
.toast {
  pointer-events: auto; display: flex; gap: 12px; align-items: flex-start;
  padding: 12px 14px; border-radius: var(--radius-sm);
  background: color-mix(in srgb, var(--surface) 96%, transparent); border: 1px solid var(--line-2); box-shadow: var(--shadow);
  animation: tin .22s ease-out;
}
.toast .tic { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; flex: 0 0 auto; color: #fff; background: var(--blue-2); }
.toast .tic .ic { width: 13px; height: 13px; stroke-width: 3; }
.toast.ok .tic { background: var(--ok); }
.toast.bad .tic { background: var(--danger); }
.toast b { display: block; font-size: 13px; color: #fff; }
.toast span { display: block; font-size: 12px; color: var(--text-2); }
.toast.out { animation: tout .2s ease-in forwards; }
@keyframes tin { from { opacity: 0; transform: translateY(-6px); } }
@keyframes tout { to { opacity: 0; transform: translateY(-6px); } }

.spinner { width: 34px; height: 34px; border-radius: 50%; border: 3px solid var(--accent-line); border-top-color: var(--primary-2); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.muted { color: var(--text-2); }
.mono { font-family: var(--mono); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* ================================================================ site */

.page-bg {
  background:
    radial-gradient(60% 50% at 80% -10%, var(--accent-soft), transparent 60%),
    radial-gradient(50% 50% at -10% 100%, var(--accent-tint), transparent 60%),
    var(--bg);
  min-height: 100vh;
}
.wrap { width: min(1160px, 100% - 32px); margin: 0 auto; }

.nav-top { position: sticky; top: 0; z-index: 20; backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); background: color-mix(in srgb, var(--bg) 72%, transparent); border-bottom: 1px solid var(--line); }
.nav-top .wrap { display: flex; align-items: center; gap: 14px; height: 64px; }
.nav-top .sp { flex: 1; }
.nav-top a.link { color: var(--text-2); text-decoration: none; font-weight: 500; font-size: 13.5px; padding: 8px 10px; border-radius: 8px; }
.nav-top a.link:hover { color: #fff; background: var(--accent-tint); }
a.btn { text-decoration: none; }
.userchip { display: inline-flex; align-items: center; gap: 9px; padding: 4px 12px 4px 4px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--surface-2); font-size: 13px; font-weight: 600; color: #fff; text-decoration: none; }
.userchip .av { width: 28px; height: 28px; font-size: 11px; }
@media (max-width: 640px) { .nav-top a.link.hide-sm, .userchip span.n { display: none; } }

.h-display { font: 700 clamp(30px, 5vw, 54px)/1.08 var(--font-display); letter-spacing: -.02em; color: #fff; margin: 0; }
.h-display b { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { font-size: clamp(15px, 1.6vw, 18px); color: var(--text-2); max-width: 620px; }
.eyebrow { font-size: 11px; font-weight: 700; letter-spacing: .3em; text-transform: uppercase; color: var(--text-3); }
.section-title { font: 700 26px/1.2 var(--font-display); color: #fff; margin: 0 0 6px; }

.chip { display: inline-flex; align-items: center; gap: 6px; padding: 3px 9px; border-radius: 999px; font-size: 11.5px; font-weight: 600; border: 1px solid var(--line-2); color: var(--text-2); background: var(--surface-2); }
.chip.ok { color: var(--ok-text); border-color: color-mix(in srgb, var(--online) 30%, transparent); background: color-mix(in srgb, var(--online) 8%, transparent); }
.chip.warn { color: var(--busy-text); border-color: color-mix(in srgb, var(--busy) 30%, transparent); background: color-mix(in srgb, var(--busy) 8%, transparent); }
.chip.bad { color: var(--danger-text); border-color: color-mix(in srgb, var(--danger) 35%, transparent); background: color-mix(in srgb, var(--danger) 8%, transparent); }
.chip.pro { color: var(--on-accent); border-color: transparent; background: var(--grad); }

.banner { display: flex; gap: 14px; align-items: center; padding: 14px 16px; border-radius: 12px; border: 1px solid var(--accent-line); background: var(--grad-soft); }
.banner .grow { flex: 1; min-width: 0; }
.banner b { color: #fff; }
.banner.warn { border-color: color-mix(in srgb, var(--busy) 35%, transparent); background: linear-gradient(135deg, color-mix(in srgb, var(--busy) 12%, transparent), color-mix(in srgb, var(--danger) 6%, transparent)); }

.foot { border-top: 1px solid var(--line); padding: 28px 0 40px; color: var(--text-3); font-size: 12.5px; }
.foot .wrap { display: flex; gap: 16px; flex-wrap: wrap; align-items: center; }
.foot .sp { flex: 1; }

.err-box { display: flex; gap: 8px; align-items: center; color: var(--danger-text); font-size: 12.5px; }

/* ---------------------------------------------------------------- arte
   Imagens neutras (preto e cinza) que o tema pode trocar ou desligar:
       :root { --art-room: none; }                                            */
:root {
  --art-room: url(/assets/art/fundo-sala.webp);    /* atras da chamada */
  --art-tile: url(/assets/art/quadro.webp);        /* quadro de quem esta' sem camera */
  --art-avatars: url(/assets/art/avatares.webp);   /* 16 personagens, grade 4x4 */
  /* grao fino por cima dos dois fundos: e' o navegador que desenha, no tamanho da tela, entao nunca fica
     esticado nem comprimido; tambem esconde os degraus do degrade' escuro */
  --art-grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='256' height='256'%3E%3Cfilter id='g' x='0' y='0' width='100%25' height='100%25'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 .9 0 0 0 -.38'/%3E%3C/filter%3E%3Crect width='256' height='256' filter='url(%23g)' opacity='.045'/%3E%3C/svg%3E");
}
html[data-theme="classico"] { --art-room: none; --art-tile: none; --art-grain: none; }

/* personagem no lugar das iniciais: escolhido pelo nome (avatarPaint, em icons.js) */
.av.pic { background-image: var(--art-avatars); background-size: 400% 400%; background-repeat: no-repeat; background-color: var(--surface-3); color: transparent; text-shadow: none; overflow: hidden; }

.av.photo { background-size: cover; background-position: center; }

/* menu da conta (clique no seu avatar, no cabecalho) */
button.userchip { cursor: pointer; font-family: var(--font); }
.userchip .chev { width: 14px; height: 14px; color: var(--text-3); transition: transform .15s; }
.userchip.open .chev { transform: rotate(180deg); }
.umenu { position: fixed; z-index: 60; width: 260px; padding: 6px; border-radius: 12px; background: var(--deep); border: 1px solid var(--line-2); box-shadow: var(--shadow); }
.umenu .uhead { display: flex; align-items: center; gap: 11px; padding: 10px 10px 12px; margin-bottom: 4px; border-bottom: 1px solid var(--line); }
.umenu .uhead .av { width: 42px; height: 42px; font-size: 15px; }
.umenu .uhead b { display: block; color: var(--title); font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.umenu .uhead small { display: block; color: var(--text-3); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.umenu .uhead > div { min-width: 0; }
.umenu a, .umenu button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 10px; border: 0; border-radius: 8px; background: transparent; color: var(--text-2); font: 500 13.5px var(--font); text-decoration: none; cursor: pointer; text-align: left; }
.umenu a:hover, .umenu button:hover { background: var(--surface-3); color: var(--title); }
.umenu .sep { height: 1px; margin: 4px 6px; background: var(--line); }
.umenu .bad { color: var(--danger-text); }

/* ---------------------------------------------------------------- ajustes de tema */

/* o logo e' roxo: nos temas neutros ele vai junto para o cinza */
.brand .logo, img[src$="/assets/logo.svg"] { filter: var(--logo-filter, grayscale(1) brightness(1.75)); }
html[data-theme="classico"] { --logo-filter: none; }
html.has-accent { --logo-filter: none; }
/* interruptor ligado: a bolinha contrasta com o destaque, seja ele claro ou escuro */
.switch input:checked + span::after { background: var(--on-accent); }
.toast .tic { background: var(--info); }
input[type="range"]::-webkit-slider-thumb { background: var(--bg); border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-ring); }
input[type="range"]::-moz-range-thumb { background: var(--bg); border-color: var(--accent); }

/* ================================================================ temas
   O padrao (acima, em :root) e' o preto. Cada tema so' troca variaveis: e' o que
   o CSS personalizado das contas premium tambem pode fazer, por exemplo
       :root { --bg: #000; --accent: #ff7a45; }                                */

/* grafite: cinza um pouco mais claro */
html[data-theme="grafite"] {
  --bg: #1b1c1f; --bg-2: #202125; --inset: #18191c; --deep: #111214;
  --surface: #25262b; --surface-2: #2b2d32; --surface-3: #33353b;
  --line: #34363c; --line-2: #42444c; --line-3: #54565f;
  --track: #3a3c43; --track-2: #474951;
  --text: #e4e5e9; --text-2: #b0b2ba; --text-3: #7d7f89;
}

/* classico: o azul-marinho com roxo de antes */
html[data-theme="classico"] {
  --bg: #050b19; --bg-2: #08101f; --inset: #0a1226; --deep: #02060f;
  --surface: #0b1428; --surface-2: #0f1a33; --surface-3: #131f3d;
  --line: #1a2546; --line-2: #26305a; --line-3: #3a4580;
  --track: #1d2547; --track-2: #2a3360;
  --text: #e6e7f7; --text-2: #a9adcc; --text-3: #6d7398;
  --accent: #682dfb; --accent-2: #7a45ff; --accent-3: #4948fb; --on-accent: #ffffff; --accent-text: #c9b8ff;
  --accent-tint: rgba(104, 45, 251, .09); --accent-soft: rgba(104, 45, 251, .2); --accent-line: rgba(104, 45, 251, .45);
  --accent-ring: rgba(104, 45, 251, .24); --accent-shadow: rgba(84, 36, 220, .4);
  --link: #4582fc; --magenta: #be32e4; --online: #30f96f; --ok: #17b552; --ok-text: #7dffa7;
  --busy: #f5a524; --busy-text: #ffc56b; --danger: #e5304a; --danger-text: #ff8a9a; --info: #4582fc;
  --av-1: linear-gradient(135deg, #7a45ff, #4948fb); --av-2: linear-gradient(135deg, #be32e4, #682dfb);
  --av-3: linear-gradient(135deg, #4582fc, #4948fb); --av-4: linear-gradient(135deg, #17b552, #2b8a6e);
  --av-5: linear-gradient(135deg, #f5a524, #e5304a); --av-6: linear-gradient(135deg, #4582fc, #be32e4);
}

/* cor de destaque escolhida pela pessoa (theme.js poe --accent, --accent-2, --accent-3 e --on-accent) */
html.has-accent {
  --accent-text: color-mix(in srgb, var(--accent) 55%, #fff);
  --accent-tint: color-mix(in srgb, var(--accent) 9%, transparent);
  --accent-soft: color-mix(in srgb, var(--accent) 19%, transparent);
  --accent-line: color-mix(in srgb, var(--accent) 44%, transparent);
  --accent-ring: color-mix(in srgb, var(--accent) 26%, transparent);
  --accent-shadow: color-mix(in srgb, var(--accent) 32%, transparent);
  --link: color-mix(in srgb, var(--accent) 60%, #fff);
}

/* ---------------------------------------------------------------- markdown das mensagens (md.js) */
.md-ic { font: .86em/1.3 var(--mono); padding: .1em .35em; border-radius: 4px; background: var(--surface-3); border: 1px solid var(--line-2); color: var(--text); white-space: pre-wrap; }
.md-pre { position: relative; margin: 5px 0 3px; max-width: 760px; border-radius: 8px; background: var(--inset); border: 1px solid var(--line-2); }
.md-pre pre { margin: 0; padding: 9px 12px; font: 13px/1.5 var(--mono); color: var(--text); white-space: pre-wrap; word-break: break-word; tab-size: 4; max-height: 480px; overflow: auto; }
.md-lang { position: absolute; top: 5px; right: 70px; font: 600 10.5px var(--mono); color: var(--text-3); pointer-events: none; opacity: 0; transition: opacity .12s; }
.md-copy { position: absolute; top: 4px; right: 5px; height: 22px; padding: 0 8px; border-radius: 6px; border: 1px solid var(--line-3); background: var(--surface-2); color: var(--text-2); font: 600 11px var(--font); cursor: pointer; opacity: 0; transition: opacity .12s; }
.md-pre:hover .md-copy, .md-pre:hover .md-lang, .md-copy:focus-visible { opacity: 1; }
.md-copy:hover { color: var(--title); background: var(--surface-3); }
.md-k { color: #c9a6ef; }
.md-s { color: #a6d9a0; }
.md-n { color: #eab97f; }
.md-c { color: var(--text-3); font-style: italic; }
.md-q { margin: 2px 0; padding: 0 0 0 12px; border-left: 4px solid var(--line-3); border-radius: 2px; }
.md-h { color: var(--title); font-family: var(--font-display); font-weight: 700; line-height: 1.3; margin: 6px 0 2px; }
.md-h1 { font-size: 1.5em; }
.md-h2 { font-size: 1.25em; }
.md-h3 { font-size: 1.08em; }
.md-sub { font-size: .82em; color: var(--text-3); }
.md-list { margin: 2px 0; padding-left: 24px; white-space: normal; }
.md-list li { white-space: pre-wrap; margin: 1px 0; }
.md-list .md-list { margin: 0; }
.md-sp { border-radius: 4px; padding: 0 2px; background: var(--surface-3); color: transparent; cursor: pointer; transition: background .15s; }
.md-sp:hover { background: var(--track-2); }
.md-sp:not(.open) * { opacity: 0; pointer-events: none; }
.md-sp.open { background: var(--accent-soft); color: inherit; cursor: auto; }
.md-ts { padding: 0 3px; border-radius: 4px; background: var(--accent-soft); }
.md-ml { color: var(--link); }
a.md-ml:hover, .md-q a:hover { text-decoration: underline; }

/* /app dentro da guilda (Início com a chamada no cantinho): sem o cabeçalho do site */
.embed-home .nav-top { display: none; }

/* ---------------------------------------------------------------- editor do perfil em janela (profile.js) */
html.ssp-lock, html.ssp-lock body { overflow: hidden; }
.ssp-ov { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; padding: 16px; background: rgba(0, 0, 0, .66); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); animation: sspIn .14s ease-out; }
@keyframes sspIn { from { opacity: 0; } to { opacity: 1; } }
.ssp { width: min(980px, 100%); max-height: min(92vh, 900px); display: grid; grid-template-rows: auto minmax(0, 1fr) auto; border-radius: 16px; background: var(--bg-2); border: 1px solid var(--line-2); box-shadow: 0 30px 80px rgba(0, 0, 0, .6); overflow: hidden; animation: sspUp .16s ease-out; }
@keyframes sspUp { from { transform: translateY(10px) scale(.985); } to { transform: none; } }
.ssp-head { display: flex; align-items: center; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.ssp-head > div { flex: 1; }
.ssp-head h2 { margin: 2px 0 0; font: 700 22px var(--font-display); color: var(--title); }
.ssp-body { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 22px; padding: 18px 20px; overflow-y: auto; }
.ssp-form { display: grid; gap: 14px; align-content: start; }
.ssp-form section { display: grid; gap: 10px; padding: 16px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); }
.ssp-form h3 { margin: 0; color: var(--title); font: 600 15px var(--font-display); }
.ssp-sub { margin: -4px 0 0; font-size: 12.5px; color: var(--text-3); }
.ssp-form .lbl { margin: 4px 0 0; }
.ssp-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.ssp-avgrid { display: grid; grid-template-columns: repeat(8, 1fr); gap: 8px; }
.ssp-avgrid button { position: relative; aspect-ratio: 1; padding: 0; border-radius: 50%; border: 2px solid transparent; background: none; cursor: pointer; transition: transform .12s, border-color .12s; }
.ssp-avgrid button:hover { transform: scale(1.06); }
.ssp-avgrid button.on { border-color: var(--title); box-shadow: 0 0 0 3px var(--bg-2); }
.ssp-avgrid button .av { width: 100%; height: 100%; }
.ssp-colors { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.ssp-colors button { width: 30px; height: 30px; border-radius: 8px; border: 2px solid transparent; cursor: pointer; }
.ssp-colors button.on { border-color: var(--title); box-shadow: 0 0 0 2px var(--bg-2); }
.ssp-colors input[type="color"] { width: 44px; height: 32px; padding: 2px; border-radius: 8px; border: 1px solid var(--line-2); background: var(--inset); cursor: pointer; }
.ssp-count { font: 600 11.5px var(--mono); color: var(--text-3); text-align: right; }
.ssp-kinds { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.ssp-kinds .kind { display: grid; gap: 8px; padding: 10px; border-radius: 12px; border: 2px solid var(--line-2); background: var(--surface-2); cursor: pointer; color: var(--text); font: 600 13px var(--font); text-align: left; }
.ssp-kinds .kind.on { border-color: var(--title); }
.ssp-kinds .kind i { display: block; height: 40px; border-radius: 8px; border: 1px solid rgba(255, 255, 255, .08); }
.ssp-prem { display: grid; gap: 8px; }
.ssp-prem.locked { opacity: .5; pointer-events: none; }
.ssp-css { font: 12.5px/1.5 var(--mono); min-height: 110px; resize: vertical; white-space: pre; tab-size: 2; }
.ssp-side { position: sticky; top: 0; align-self: start; display: grid; gap: 10px; }
.ssp-card { border-radius: 16px; overflow: hidden; background: var(--deep); border: 1px solid var(--line-2); box-shadow: var(--shadow); }
.ssp-ban { height: 128px; background: linear-gradient(135deg, var(--surface-3), var(--surface)); background-size: cover; background-position: center; }
.ssp-pav { margin: -46px 0 0 16px; }
.ssp-pav .av { width: 92px; height: 92px; font-size: 30px; box-shadow: 0 0 0 6px var(--deep); }
.ssp-pb { padding: 10px 16px 18px; display: grid; gap: 8px; }
.ssp-pb h2 { margin: 0; color: var(--title); font: 700 20px var(--font-display); overflow-wrap: anywhere; }
.ssp-since { font-size: 12px; color: var(--text-3); }
.ssp-bio { padding: 10px 11px; border-radius: 9px; background: var(--surface); color: var(--text-2); font-size: 13.5px; line-height: 1.45; white-space: pre-wrap; word-break: break-word; }
.ssp-bio:empty { display: none; }
.ssp-badges { display: flex; flex-wrap: wrap; gap: 6px; }
.badge2 { display: inline-flex; align-items: center; padding: 3px 9px; border-radius: 999px; font-size: 11.5px; font-weight: 700; color: var(--title); background: var(--surface-3); border: 1px solid var(--line-3); }
.ssp-foot { display: flex; align-items: center; gap: 10px; padding: 12px 20px; border-top: 1px solid var(--line); background: var(--deep); }
.ssp-foot .hint { flex: 1; margin: 0; }
@media (max-width: 860px) {
  .ssp-body { grid-template-columns: 1fr; }
  .ssp-side { position: static; order: -1; }
  .ssp-avgrid { grid-template-columns: repeat(4, 1fr); }
  .ssp-kinds { grid-template-columns: 1fr; }
}
.ssp-check { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; color: var(--text); font-size: 13.5px; }
.ssp-check input { margin-top: 3px; width: 16px; height: 16px; accent-color: var(--accent); }
.ssp-check small { display: block; margin-top: 2px; color: var(--text-3); font-size: 12px; }

/* fundo do quadro na chamada (editor do perfil) */
.ssp-tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.ssp-tiles button { display: flex; align-items: center; gap: 8px; padding: 9px 10px; border-radius: 10px; border: 2px solid var(--line-2); background: var(--surface-2); color: var(--text); font: 600 12.5px var(--font); cursor: pointer; text-align: left; }
.ssp-tiles button i { width: 10px; height: 10px; border-radius: 50%; border: 2px solid var(--line-3); flex: 0 0 auto; }
.ssp-tiles button.on { border-color: var(--title); }
.ssp-tiles button.on i { border-color: var(--title); background: var(--title); }
.ssp-tilepv { position: relative; width: min(100%, 340px); aspect-ratio: 16 / 9; border-radius: 12px; overflow: hidden; border: 1px solid var(--line-2); display: grid; place-items: center;
  background: linear-gradient(160deg, var(--surface-2), var(--bg-2)); }
.ssp-tilepv .av { width: 30%; height: auto; aspect-ratio: 1; font-size: 22px; box-shadow: 0 0 0 1px var(--line-3), 0 10px 30px rgba(0, 0, 0, .5); }
.ssp-tilepv .tg { position: absolute; left: 8px; bottom: 8px; padding: 3px 8px; border-radius: 6px; background: color-mix(in srgb, var(--deep) 75%, transparent); color: #fff; font: 600 11.5px var(--font); }
@media (max-width: 560px) { .ssp-tiles { grid-template-columns: 1fr; } }

/* fundos prontos (galeria no editor do perfil) */
.ssp-fx { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.ssp-fx button { position: relative; aspect-ratio: 5 / 2; border-radius: 9px; border: 2px solid transparent; background: var(--inset) center / cover no-repeat; cursor: pointer; overflow: hidden; padding: 0; transition: transform .12s, border-color .12s; }
.ssp-fx[data-fx="tile"] button { aspect-ratio: 16 / 9; }
.ssp-fx button:hover { transform: translateY(-1px); border-color: var(--line-3); }
.ssp-fx button.on { border-color: var(--title); box-shadow: 0 0 0 2px var(--bg-2); }
.ssp-fx button span { position: absolute; left: 0; right: 0; bottom: 0; padding: 10px 6px 4px; font: 600 10.5px var(--font); color: #fff; text-align: left; background: linear-gradient(transparent, rgba(0, 0, 0, .75)); opacity: 0; transition: opacity .12s; }
.ssp-fx button:hover span, .ssp-fx button.on span { opacity: 1; }
@media (max-width: 560px) { .ssp-fx { grid-template-columns: repeat(2, 1fr); } }

/* emblemas */
img.bdg { width: 22px; height: 22px; object-fit: contain; vertical-align: middle; flex: 0 0 auto; }
img.bdg.sm { width: 16px; height: 16px; }
img.bdg.lg { width: 28px; height: 28px; }
.bdgrow { display: flex; flex-wrap: wrap; gap: 4px; padding: 4px 6px; border-radius: 8px; background: color-mix(in srgb, var(--deep) 70%, transparent); width: max-content; max-width: 100%; }

.ssp-bdgs { display: grid; grid-template-columns: repeat(auto-fill, minmax(78px, 1fr)); gap: 6px; }
.ssp-bdg { display: grid; justify-items: center; gap: 4px; padding: 8px 4px 6px; border-radius: 10px; border: 2px solid transparent; background: var(--surface-2); color: var(--text-2); cursor: pointer; font: 600 11px var(--font); }
.ssp-bdg:hover { border-color: var(--line-3); }
.ssp-bdg.on { border-color: var(--title); color: var(--title); }
.ssp-bdg.locked { cursor: default; opacity: .32; filter: grayscale(.85); }
.ssp-frames { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 6px; }
.ssp-frm { display: grid; justify-items: center; gap: 2px; padding: 6px 4px; border-radius: 10px; border: 2px solid transparent; background: var(--surface-2); color: var(--text-2); cursor: pointer; font: 600 11px var(--font); }
.ssp-frm img { width: 64px; height: 64px; }
.ssp-plates { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 6px; margin-top: 8px; }
.ssp-plt { position: relative; height: 40px; display: flex; align-items: flex-end; padding: 0 8px 4px; border-radius: 10px; border: 2px solid transparent; background: var(--surface-2) right center / cover no-repeat; color: #fff; cursor: pointer; font: 600 11px var(--font); text-shadow: 0 1px 3px rgba(0, 0, 0, .9); overflow: hidden; }
.ssp-plt.none, .ssp-plt.shop { align-items: center; justify-content: center; color: var(--text-2); text-shadow: none; }
.ssp-plt.on { border-color: var(--title); }
.ssp-platepv { display: flex; align-items: center; gap: 9px; max-width: 300px; padding: 9px 10px; border-radius: 12px; border: 1px solid var(--line-2); background: var(--deep); }
.ssp-platepv.plated { position: relative; isolation: isolate; border-color: rgba(255, 255, 255, .1); background: var(--deep) var(--plate) right center / cover no-repeat; }
.ssp-platepv.plated::before { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; background: linear-gradient(90deg, rgba(0, 0, 0, .62), rgba(0, 0, 0, .3) 50%, transparent 85%); }
.ssp-platepv b { display: block; font-size: 13px; color: var(--title); text-shadow: 0 1px 3px rgba(0, 0, 0, .8); }
.ssp-platepv small { display: block; font-size: 11.5px; color: rgba(255, 255, 255, .75); }
.ssp-frm .nb { display: grid; place-items: center; width: 64px; height: 64px; font-size: 18px; color: var(--text-3); }
.ssp-frm .nb .ic { width: 26px; height: 26px; }
.ssp-frm:hover { border-color: var(--line-3); }
.ssp-frm.on { border-color: var(--title); color: var(--title); }
.ssp-frm.shop { border: 2px dashed var(--line-3); background: transparent; color: #f6bd45; }
.ssp-bdg.shop { border: 2px dashed var(--line-3); background: transparent; color: #f6bd45; }
.ssp-bdg.shop .nb { display: grid; place-items: center; height: 40px; }
.ssp-bdg.shop .ic { width: 26px; height: 26px; }
.ssp-bdg.locked:hover { border-color: transparent; }
.ssp-bdg .nb { height: 28px; display: grid; place-items: center; font-size: 18px; color: var(--text-3); }
.ssp-pb h2 img.bdg { margin-left: 6px; vertical-align: -4px; }

/* ---------------------------------------------------------------- ajuda (F1), tour e comandos / */
.hlp-ov { position: fixed; inset: 0; z-index: 95; display: grid; place-items: center; padding: 16px; background: rgba(0, 0, 0, .6); backdrop-filter: blur(2px); animation: sspIn .12s ease-out; }
.hlp { width: min(720px, 100%); max-height: min(86vh, 760px); display: grid; grid-template-rows: auto auto minmax(0, 1fr) auto; border-radius: 14px; background: var(--bg-2); border: 1px solid var(--line-2); box-shadow: 0 30px 80px rgba(0, 0, 0, .6); overflow: hidden; }
.hlp-head { display: flex; align-items: center; gap: 10px; padding: 14px 18px 8px; }
.hlp-head b { color: var(--title); font: 700 18px var(--font-display); }
.hlp-head .sp { flex: 1; }
.hlp-tabs { display: flex; gap: 4px; padding: 0 14px; border-bottom: 1px solid var(--line); }
.hlp-tabs button { padding: 9px 12px; border: 0; border-bottom: 2px solid transparent; background: none; color: var(--text-2); font: 600 13px var(--font); cursor: pointer; }
.hlp-tabs button.on { color: var(--title); border-bottom-color: var(--title); }
.hlp-body { overflow-y: auto; padding: 14px 18px 18px; }
.hlp-body h4 { margin: 6px 0 8px; color: var(--title); font: 600 13px var(--font); text-transform: uppercase; letter-spacing: .04em; }
.hlp-p { margin: 0 0 12px; color: var(--text-2); font-size: 13.5px; }
.hlp-keys { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 18px; margin-bottom: 14px; }
.hlp-keys div { display: flex; align-items: center; gap: 10px; min-width: 0; font-size: 13px; color: var(--text-2); }
.hlp-keys kbd, .hlp-keys code { flex: 0 0 auto; padding: 3px 7px; border-radius: 6px; background: var(--surface-3); border: 1px solid var(--line-3); border-bottom-width: 2px; color: var(--title); font: 600 11.5px var(--mono); white-space: nowrap; }
.hlp-keys.md code { border-bottom-width: 1px; font-weight: 500; }
.hlp-how { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.hlp-how div { padding: 12px; border-radius: 10px; background: var(--surface); border: 1px solid var(--line); }
.hlp-how b { color: var(--title); font-size: 13.5px; }
.hlp-how p { margin: 4px 0 0; font-size: 12.5px; line-height: 1.5; color: var(--text-2); }
.hlp-foot { display: flex; gap: 8px; justify-content: flex-end; padding: 10px 18px; border-top: 1px solid var(--line); background: var(--deep); }
.hlp-foot:empty { display: none; }
@media (max-width: 640px) { .hlp-keys, .hlp-how { grid-template-columns: 1fr; } }
.tour-spot { position: fixed; z-index: 96; border-radius: 12px; box-shadow: 0 0 0 9999px rgba(0, 0, 0, .62), 0 0 0 2px var(--title); pointer-events: none; transition: left .25s, top .25s, width .25s, height .25s; }
.tour-card { position: fixed; z-index: 97; width: 300px; padding: 14px 16px 12px; border-radius: 12px; background: var(--bg-2); border: 1px solid var(--line-2); box-shadow: 0 20px 50px rgba(0, 0, 0, .6); transition: left .25s, top .25s; }
.tour-card .tour-n { font: 600 11px var(--font); color: var(--text-3); text-transform: uppercase; letter-spacing: .05em; }
.tour-card b { display: block; margin: 4px 0 4px; color: var(--title); font: 700 15px var(--font-display); }
.tour-card p { margin: 0 0 12px; font-size: 13px; line-height: 1.5; color: var(--text-2); }
.tour-acts { display: flex; gap: 6px; align-items: center; }
.tour-acts .sp { flex: 1; }
.slashpop { position: absolute; left: 16px; right: 16px; bottom: calc(100% - 8px); z-index: 30; max-height: 300px; overflow-y: auto; padding: 6px; border-radius: 10px; background: var(--deep); border: 1px solid var(--line-2); box-shadow: 0 -10px 30px rgba(0, 0, 0, .45); }
.slashpop[hidden] { display: none; }
.slashpop .sh { padding: 4px 8px 6px; font: 600 11px var(--font); color: var(--text-3); text-transform: uppercase; letter-spacing: .05em; }
.slashpop button { display: flex; align-items: baseline; gap: 10px; width: 100%; padding: 7px 8px; border: 0; border-radius: 6px; background: transparent; color: var(--text-2); font: 13.5px var(--font); text-align: left; cursor: pointer; }
.slashpop button b { color: var(--title); font-weight: 600; white-space: nowrap; }
.slashpop button i { font-style: normal; color: var(--text-3); font: 12px var(--mono); }
.slashpop button.on { background: var(--surface-3); }

.umenu [data-act="install"] { display: none; }
html.can-install .umenu [data-act="install"] { display: flex; }

/* ---------------------------------------------------------------- visualizador de anexos (viewer.js) */
html.vw-lock, html.vw-lock body { overflow: hidden; }
.vw-ov { position: fixed; inset: 0; z-index: 98; display: grid; grid-template-rows: auto minmax(0, 1fr); background: rgba(4, 4, 6, .9); -webkit-backdrop-filter: blur(14px) saturate(.6); backdrop-filter: blur(14px) saturate(.6); animation: sspIn .12s ease-out; }
.vw-top { display: flex; align-items: center; gap: 10px; padding: 10px 14px; background: linear-gradient(rgba(0, 0, 0, .6), transparent); z-index: 2; }
.vw-top .sp { flex: 1; }
.vw-info { min-width: 0; display: grid; }
.vw-info b { color: #fff; font: 600 14px var(--font); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vw-info small { color: rgba(255, 255, 255, .65); font-size: 12px; }
.vw-zoom { display: flex; align-items: center; gap: 4px; }
.vw-zoom .vw-z { min-width: 46px; text-align: center; color: #fff; font: 600 12px var(--mono); }
.vw-ov.isvideo .vw-zoom { display: none; }
.vw-top .ibtn { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .12); color: #fff; }
.vw-top .ibtn:hover { background: rgba(255, 255, 255, .16); }
.vw-stage { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); place-items: center; overflow: hidden; touch-action: none; padding: 8px 64px 24px; min-height: 0; }
.vw-media { max-width: 100%; max-height: 100%; width: auto; height: auto; min-width: 0; min-height: 0; object-fit: contain; border-radius: 6px; transform-origin: center center; transition: transform .08s ease-out; user-select: none; box-shadow: 0 20px 60px rgba(0, 0, 0, .6); cursor: zoom-in; }
.vw-media.zoomed { cursor: grab; transition: none; }
video.vw-media { cursor: auto; width: min(100%, 1280px); background: #000; }
.vw-nav { position: absolute; top: 50%; z-index: 3; width: 44px; height: 64px; margin-top: -32px; border: 0; border-radius: 10px; background: rgba(255, 255, 255, .08); color: #fff; font-size: 34px; line-height: 1; cursor: pointer; }
.vw-nav:hover { background: rgba(255, 255, 255, .18); }
.vw-prev { left: 12px; } .vw-next { right: 12px; }
.vw-nav[hidden] { display: none; }
@media (max-width: 640px) { .vw-stage { padding: 4px 4px 16px; } .vw-nav { display: none; } }
/* anexos: imagem clicavel, video com botao de ampliar, contador */
.att a[data-view] { display: inline-block; cursor: zoom-in; }
.att .vwrap { position: relative; display: inline-block; max-width: 100%; }
.att .vwrap .vexp { position: absolute; top: 8px; right: 8px; opacity: 0; transition: opacity .12s; background: rgba(0, 0, 0, .6); border-color: rgba(255, 255, 255, .15); color: #fff; }
.att .vwrap:hover .vexp { opacity: 1; }
.att .exp { white-space: nowrap; }
.att .exp.warn { color: var(--busy-text); font-weight: 600; }
.att .exp.gone { color: var(--danger-text); }
.att.expired img, .att.expired video { opacity: .35; filter: grayscale(.7); }
/* moldura em volta do avatar: o furo da imagem e' 1/2,11 dela; 203% deixa o avatar um pouco por baixo do aro */
.av.framed { overflow: visible; }
.av .avframe { position: absolute; left: 50%; top: 50%; width: 203%; height: 203%; max-width: none; transform: translate(-50%, -50%); pointer-events: none; z-index: 1; }
/* alcas de redimensionar (dragResize) */
.rsz { position: absolute; top: 0; bottom: 0; width: 8px; z-index: 6; cursor: col-resize; touch-action: none; }
.rsz::after { content: ""; position: absolute; top: 0; bottom: 0; left: 3px; width: 2px; background: transparent; transition: background .12s; }
.rsz:hover::after, html.resizing .rsz::after { background: var(--line-3); }
html.resizing, html.resizing * { cursor: col-resize !important; user-select: none !important; }
html.resizing iframe { pointer-events: none; }
/* cartao de arquivo: nome comprido corta com "..." e nada passa da largura do chat */
.att { min-width: 0; max-width: 100%; }
.att .fcard { min-width: 0; box-sizing: border-box; }
.att .fcard .fn { flex: 1; min-width: 0; display: grid; }
.att .fcard .fn b, .att .fcard .fn small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.att .fcard .fic, .att .fcard .dl { flex: 0 0 auto; }
/* leva de arquivos */
.attgrp.multi { display: grid; grid-template-columns: minmax(0, 1fr); box-sizing: border-box; gap: 6px; max-width: min(520px, 100%); padding: 8px; border-radius: 12px; background: var(--bg-2); border: 1px solid var(--line-2); margin-top: 4px; }
.attgrp.multi .att { margin: 0; position: relative; }
.attgrp.multi .fcard { max-width: none; width: 100%; }
.attgrp.imgs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.attgrp.imgs .attbar { grid-column: 1 / -1; }
.attgrp.imgs .att a[data-view], .attgrp.imgs .att img { display: block; width: 100%; }
.attgrp.imgs .att img { height: 170px; object-fit: cover; border-radius: 8px; }
.attgrp.imgs .att .meta { display: none; }
.attbar { display: flex; align-items: center; gap: 10px; padding: 0 2px 2px; color: var(--text-3); font: 600 12px var(--font); }
.attbar span { flex: 1; }
.attbar .btn .ic { width: 15px; height: 15px; }
.att .attx { position: absolute; top: 6px; right: 6px; width: 26px; height: 26px; border: 0; border-radius: 7px; display: none; place-items: center; background: rgba(0, 0, 0, .65); color: #fff; cursor: pointer; }
.att:hover .attx { display: grid; }
.att .attx:hover { color: var(--danger-text); }

/* ---------------------------------------------------------------- emojis e menções (emoji.js, md.js) */
.sugpop { position: absolute; left: 16px; right: 16px; bottom: calc(100% - 8px); z-index: 30; max-height: 320px; overflow-y: auto; padding: 6px; border-radius: 10px; background: var(--deep); border: 1px solid var(--line-2); box-shadow: 0 -10px 30px rgba(0, 0, 0, .45); }
.sugpop[hidden] { display: none; }
.sugpop .sh { padding: 4px 8px 6px; font: 600 11px var(--font); color: var(--text-3); text-transform: uppercase; letter-spacing: .05em; }
.sugpop button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 6px 8px; border: 0; border-radius: 6px; background: transparent; color: var(--text-2); font: 13.5px var(--font); text-align: left; cursor: pointer; }
.sugpop button b { color: var(--title); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sugpop button span:last-child:not(.si) { margin-left: auto; color: var(--text-3); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 45%; }
.sugpop button.on, .sugpop button:hover { background: var(--surface-2); }
.sugpop .si { width: 24px; height: 24px; flex: 0 0 auto; display: grid; place-items: center; font-size: 20px; line-height: 1; }
.sugpop .si .av { width: 24px; height: 24px; font-size: 9px; }
.emp { position: fixed; z-index: 96; display: grid; grid-template-rows: auto auto minmax(0, 1fr) auto; border-radius: 12px; background: var(--deep); border: 1px solid var(--line-2); box-shadow: 0 18px 50px rgba(0, 0, 0, .55); overflow: hidden; animation: sspIn .1s ease-out; }
.emp-top { display: flex; gap: 8px; padding: 10px; border-bottom: 1px solid var(--line); }
.emp-q { flex: 1; min-width: 0; height: 34px; padding: 0 10px; border-radius: 8px; border: 1px solid var(--line-2); background: var(--surface-2); color: var(--title); font: 14px var(--font); outline: none; }
.emp-q:focus { border-color: var(--line-3); }
.emp-tone, .emp-tones button { width: 34px; height: 34px; border: 0; border-radius: 8px; background: var(--surface-2); font-size: 18px; cursor: pointer; }
.emp-tones { display: flex; gap: 4px; justify-content: flex-end; padding: 6px 10px; border-bottom: 1px solid var(--line); }
.emp-tones[hidden] { display: none; }
.emp-tones button.on { outline: 2px solid var(--title); }
.emp-body { grid-row: 3; display: grid; grid-template-columns: 44px minmax(0, 1fr); min-height: 0; }   /* a faixa dos tons some: sem as linhas fixas, o rodape ficava fora */
.emp-foot { grid-row: 4; }
.emp-tabs { display: flex; flex-direction: column; gap: 2px; padding: 6px 4px; overflow-y: auto; border-right: 1px solid var(--line); background: var(--bg-2); scrollbar-width: none; }
.emt { width: 36px; height: 34px; flex: 0 0 auto; border: 0; border-radius: 8px; background: transparent; font-size: 19px; cursor: pointer; filter: grayscale(.85); opacity: .7; }
.emt:hover, .emt.on { filter: none; opacity: 1; background: var(--surface-2); }
.emp-grid { overflow-y: auto; padding: 0 8px 8px; position: relative; }
.emp-h { position: sticky; top: 0; z-index: 1; padding: 8px 4px 6px; background: var(--deep); font: 600 11px var(--font); color: var(--text-3); text-transform: uppercase; letter-spacing: .05em; }
.emp-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(38px, 1fr)); }
.emb { height: 38px; border: 0; border-radius: 8px; background: transparent; font-size: 24px; line-height: 1; cursor: pointer; font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif; }
.emb:hover { background: var(--surface-2); }
.emb.geb { display: grid; place-items: center; padding: 0; }
.emb.geb img.ge { max-width: 30px; max-height: 30px; width: auto; height: auto; }
.emt.gt { display: grid; place-items: center; padding: 0; font: 700 11px var(--font); color: var(--title); filter: none; opacity: .85; }
.emt.gt img { width: 26px; height: 26px; border-radius: 8px; object-fit: cover; }
.emp-big img.ge { max-width: 32px; max-height: 32px; width: auto; height: auto; display: block; }
.sugpop .si img.ge { height: 20px; width: auto; max-width: 26px; display: block; margin: 0 auto; }
/* emoji da guilda no meio do texto: do tamanho de um emoji comum (grande quando a mensagem so' tem emojis) */
img.ge { height: 1.45em; width: auto; max-width: 3.2em; vertical-align: -.35em; object-fit: contain; border: 0; border-radius: 0; background: none; }
.md-jumbo img.ge { height: 48px; max-width: 110px; vertical-align: bottom; }
.emp-msg { padding: 30px 10px; text-align: center; color: var(--text-3); font-size: 13px; }
.emp-foot { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-top: 1px solid var(--line); background: var(--bg-2); min-height: 52px; }
.emp-big { font-size: 28px; line-height: 1; }
.emp-fi { min-width: 0; display: grid; }
.emp-fi b { color: var(--title); font: 600 13px var(--font); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.emp-fi small { color: var(--text-3); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.md-men { padding: 0 3px; border-radius: 4px; background: var(--accent-soft, rgba(88, 101, 242, .22)); color: var(--title); font-weight: 600; cursor: pointer; }
.md-men:hover { background: var(--accent-line, rgba(88, 101, 242, .4)); text-decoration: underline; }
.md-men.role { cursor: default; }
.md-men.role:hover { text-decoration: none; }
.md-men.me, .md-men.all { background: rgba(240, 178, 50, .22); color: #f6d38b; }
.md-jumbo { font-size: 44px !important; line-height: 1.2 !important; }
.md-jumbo .ed, .md-jumbo .md-sub { font-size: 11px; }
.toast.click { cursor: pointer; pointer-events: auto; }
.toast.click:hover { border-color: var(--line-3); }

/* ================================================================ novidades (news.js): landing e Inicio */
.nwlist { display: grid; }
.nw { display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; gap: 12px; align-items: start; padding: 14px 0; border-top: 1px solid var(--line); }
.nw:first-child { border-top: 0; }
.nw-ic { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: var(--surface-3); border: 1px solid var(--line-2); color: #fff; }
.nw-ic .ic { width: 17px; height: 17px; }
.nw-tx b { color: #fff; font-size: 14px; display: block; line-height: 1.35; }
.nw-tx p { margin: 2px 0 0; color: var(--text-2); font-size: 13px; }
.nw time { color: var(--text-3); font-size: 12px; white-space: nowrap; padding-top: 2px; }

/* celular: o botao da conta mostra so' o avatar (o nome empurrava a barra para fora da tela) */
@media (max-width: 520px) { .userchip .n { display: none; } .userchip { padding-right: 8px; } .nav-top .wrap { gap: 8px; } }

/* ---------------------------------------------------------------- chamadas do PV (guild.js e ring.js, 2026-11-28) */
.btn.ok { background: var(--online); border-color: transparent; color: #04140b; font-weight: 600; }
.btn.ok:hover:not(:disabled) { filter: brightness(1.08); background: var(--online); }
/* cartao "fulano esta' ligando" / "Chamando..." no alto da tela (nao bloqueia a pagina) */
.callcard { position: fixed; z-index: 60; top: 14px; left: 50%; transform: translateX(-50%); width: min(420px, calc(100vw - 32px)); display: flex; align-items: center; gap: 14px; padding: 14px 14px 14px 16px; border-radius: 16px; background: color-mix(in srgb, var(--surface) 92%, transparent); border: 1px solid var(--line-2); box-shadow: 0 18px 50px rgba(0, 0, 0, .55); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); animation: ccin .22s ease-out; }
@keyframes ccin { from { opacity: 0; transform: translate(-50%, -10px); } to { opacity: 1; transform: translate(-50%, 0); } }
.callcard .ccav { position: relative; flex: 0 0 auto; padding: 0; border: 0; background: transparent; cursor: pointer; border-radius: 50%; }
.callcard .ccav .av { width: 52px; height: 52px; font-size: 18px; }
.callcard.in .ccav::after, .callcard.out .ccav::after { content: ''; position: absolute; inset: -4px; border-radius: 50%; border: 2px solid var(--online); animation: ccring 1.4s ease-out infinite; pointer-events: none; }
.callcard.out .ccav::after { border-color: var(--text-3); }
@keyframes ccring { 0% { transform: scale(.92); opacity: .9; } 100% { transform: scale(1.32); opacity: 0; } }
.callcard .cctx { flex: 1; min-width: 0; display: grid; gap: 1px; }
.callcard .cctx small { color: var(--text-3); font: 600 11px var(--font); letter-spacing: .06em; text-transform: uppercase; }
.callcard .cctx b { color: var(--title); font: 600 16px var(--font-display); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.callcard .cctx span { color: var(--text-2); font-size: 12.5px; }
.callcard .ccacts { display: flex; gap: 8px; flex: 0 0 auto; }
.callcard .cbtn { width: 46px; height: 46px; border-radius: 50%; border: 0; display: grid; place-items: center; cursor: pointer; color: #fff; transition: filter .12s, transform .12s; }
.callcard .cbtn span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.callcard .cbtn .ic { width: 20px; height: 20px; }
.callcard .cbtn.no { background: var(--danger); }
.callcard .cbtn.yes { background: var(--online); color: #04140b; }
.callcard .cbtn:hover { filter: brightness(1.1); transform: translateY(-1px); }
@media (prefers-reduced-motion: reduce) { .callcard, .callcard .ccav::after { animation: none; } }

/* app de Windows: atualizacao baixada (ss.js), botao dentro do toast, marca do menu da conta */
.ss-upd { position: fixed; z-index: 70; left: 50%; top: 14px; transform: translateX(-50%); display: flex; align-items: center; gap: 12px; width: min(560px, calc(100vw - 32px)); padding: 10px 10px 10px 14px; border-radius: 14px; background: var(--deep); border: 1px solid var(--line-2); box-shadow: var(--shadow); }
.ss-upd .ui { width: 34px; height: 34px; flex: 0 0 34px; border-radius: 10px; display: grid; place-items: center; background: var(--grad); color: var(--on-accent); }
.ss-upd .ut { flex: 1; min-width: 0; }
.ss-upd .ut b { display: block; color: var(--title); font-size: 13.5px; }
.ss-upd .ut small { display: block; color: var(--text-3); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ss-upd .btn { flex: 0 0 auto; }
@media (max-width: 520px) { .ss-upd { flex-wrap: wrap; } .ss-upd .ut { flex-basis: calc(100% - 50px); } }
.toast .tbtn { margin-top: 8px; }
.umenu .uck { width: 16px; height: 16px; display: grid; place-items: center; color: var(--online); }
.umenu .uck .ic { width: 15px; height: 15px; }

/* ---------------------------------------------------------------- atividade (activity.js): "Jogando X", rich presence, status */
/* status (status.js): verde online, lua amarela ausente, vermelha com barra não perturbe, cinza vazada invisível (so' para a
   propria pessoa), cinza offline. --dot-bg: a cor de tras, que aparece no recorte */
.dot.idle { background: radial-gradient(circle at 26% 26%, var(--dot-bg, var(--bg-2)) 0 39%, transparent 42%), var(--busy); }
.dot.dnd { background: linear-gradient(var(--dot-bg, var(--bg-2)), var(--dot-bg, var(--bg-2))) center / 58% 24% no-repeat, var(--danger); }
.dot.inv { background: radial-gradient(circle, var(--dot-bg, var(--bg-2)) 0 36%, transparent 40%), #8a8a96; }
.aline { display: block; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; line-height: 1.3; color: var(--text-3); font-weight: 400; }
.aline b { color: var(--text-2); font-weight: 600; }
.acs { display: inline-flex; align-items: center; gap: 5px; min-width: 0; max-width: 100%; }
.acs .acs-t { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acs.aline { display: flex; }
.acs.big { display: flex; align-items: flex-start; gap: 7px; margin-top: 8px; padding: 8px 10px; border-radius: 10px; background: var(--surface); border: 1px solid var(--line); color: var(--text); font-size: 13px; line-height: 1.4; }
.acs.big .acs-e { font-size: 16px; line-height: 1.2; }
.acs.big .acs-t { white-space: normal; overflow-wrap: anywhere; }
.abadge { flex: 0 0 auto; width: 18px; height: 18px; display: grid; place-items: center; border-radius: 5px; overflow: hidden; color: var(--text-3); }
.abadge img { width: 100%; height: 100%; object-fit: cover; }
.abadge .ic { width: 15px; height: 15px; }
.act-list { display: grid; gap: 8px; margin-top: 10px; }
.act-blk { padding: 10px; border-radius: 10px; background: var(--surface); border: 1px solid var(--line); }
.act-cap { margin-bottom: 8px; font: 700 10.5px/1 var(--font); letter-spacing: .07em; text-transform: uppercase; color: var(--text-3); }
.act-row { display: grid; grid-template-columns: 60px minmax(0, 1fr); gap: 11px; align-items: center; }
.act-img { position: relative; width: 60px; height: 60px; border-radius: 10px; background: var(--surface-3); }
.act-img > img:first-child { width: 60px; height: 60px; border-radius: 10px; object-fit: cover; display: block; }
.act-img.none { display: grid; place-items: center; color: var(--text-2); }
.act-img.none > .ic { width: 28px; height: 28px; }
.act-sm { position: absolute; right: -5px; bottom: -5px; width: 22px; height: 22px; border-radius: 50%; object-fit: cover; background: var(--surface-3); box-shadow: 0 0 0 3px var(--surface); }
.act-tx { display: grid; gap: 1px; min-width: 0; font-size: 12.5px; line-height: 1.35; color: var(--text-2); }
.act-tx > * { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.act-n { color: var(--title); font-size: 13px; }
.act-time { color: var(--text-3); font-variant-numeric: tabular-nums; }
.act-btns { display: grid; gap: 6px; margin-top: 10px; }
.act-btn { justify-content: center; width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* cartao simples (Inicio: Ativos agora) */
.ssa-pop { position: fixed; z-index: 70; width: 300px; max-width: calc(100vw - 16px); max-height: calc(100dvh - 16px); overflow-y: auto; border-radius: 12px; background: var(--deep); border: 1px solid var(--line-2); box-shadow: var(--shadow); }
.ssa-ptop, .ssa-pvtop { height: 64px; background: linear-gradient(135deg, var(--surface-3), var(--surface)); }
.ssa-pav { position: relative; width: max-content; margin: -34px 0 0 14px; }
.ssa-pav .av { width: 68px; height: 68px; font-size: 22px; box-shadow: 0 0 0 5px var(--deep); }
.ssa-pav .dot { position: absolute; right: 2px; bottom: 2px; width: 14px; height: 14px; box-shadow: 0 0 0 4px var(--deep); }
.ssa-pbody { padding: 8px 14px 14px; }
.ssa-pbody h3 { margin: 0; display: flex; align-items: center; gap: 6px; color: var(--title); font: 700 17px var(--font-display); overflow-wrap: anywhere; }
.ssa-where { font-size: 12px; color: var(--text-3); }
.ssa-bio { margin-top: 10px; padding: 9px 10px; border-radius: 8px; background: var(--surface); color: var(--text-2); font-size: 13px; white-space: pre-wrap; word-break: break-word; }
.ssa-pacts { display: grid; margin-top: 12px; }

/* janelas (reusam .ssp-ov/.ssp do editor de perfil) */
.ssa.ssa-small { width: min(520px, 100%); }
.ssa.ssa-set { width: min(720px, 100%); }
.ssa.ssa-ed { width: min(1000px, 100%); }
.ssa-body { padding: 16px 20px; overflow-y: auto; display: grid; gap: 12px; align-content: start; min-height: 0; }
.ssa-form { display: grid; gap: 14px; align-content: start; min-width: 0; }
.ssa-form section { display: grid; gap: 10px; padding: 16px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); min-width: 0; }
.ssa-form h3 { margin: 0; color: var(--title); font: 600 15px var(--font-display); }
.ssa-f { display: grid; gap: 5px; min-width: 0; }
.ssa-f .lbl { margin: 0; }
.ssa-f .hint { margin: 0; }
.ssa-2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; }
.ssa-sp { flex: 1; }
.ssa .ssp-foot .hint { flex: 1; margin: 0; }
.ssa-strow { display: flex; gap: 8px; align-items: center; }
.ssa-strow .field { flex: 1; min-width: 0; }
.ssa-emo { width: 42px; height: 42px; flex: 0 0 42px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--inset); color: var(--text-2); font-size: 22px; line-height: 1; cursor: pointer; display: grid; place-items: center; }
.ssa-emo:hover { border-color: var(--line-3); }
.ssa-slot { display: grid; gap: 8px; padding: 10px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line); }
.ssa-slot.busy { opacity: .6; pointer-events: none; }
.ssa-slotrow { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ssa-slotrow > b { flex: 1; color: var(--title); font-size: 13px; }
.ssa-thumb { width: 44px; height: 44px; border-radius: 9px; overflow: hidden; background: var(--surface-3); display: grid; place-items: center; color: var(--text-3); flex: 0 0 auto; }
.ssa-thumb img { width: 100%; height: 100%; object-fit: cover; }
.ssa-gal { position: fixed; z-index: 95; width: min(340px, calc(100vw - 16px)); max-height: 300px; overflow-y: auto; padding: 8px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; border-radius: 12px; background: var(--deep); border: 1px solid var(--line-2); box-shadow: var(--shadow); }
.ssa-gal .hint { grid-column: 1 / -1; margin: 4px; }
.ssa-galitem { display: grid; gap: 3px; padding: 4px; border-radius: 8px; border: 1px solid transparent; background: none; color: var(--text-3); cursor: pointer; font: 11px var(--font); min-width: 0; }
.ssa-galitem:hover { border-color: var(--line-3); background: var(--surface-2); }
.ssa-galitem img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 6px; }
.ssa-galitem small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ssa-party { display: flex; align-items: center; gap: 8px; }
.ssa-party .field { width: 90px; }
.ssa-edgrid { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 20px; align-items: start; }
.ssa-side { position: sticky; top: 0; display: grid; gap: 10px; }
.ssa-pv { border-radius: 14px; overflow: hidden; background: var(--deep); border: 1px solid var(--line-2); box-shadow: var(--shadow); padding-bottom: 6px; }
.ssa-pvtop { height: 84px; }
.ssa-pvempty { margin-top: 10px; }
.ssa-cur { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; justify-content: space-between; }
.ssa-cur .acs.big { margin: 0; flex: 1; min-width: 0; }
.ssa-cur .aline { font-size: 13px; flex: 1; }
.ssa-noapp { display: flex; gap: 14px; align-items: flex-start; padding: 14px; border-radius: 12px; border: 1px dashed var(--line-3); background: var(--surface-2); }
.ssa-noapp p { margin: 4px 0 10px; color: var(--text-2); font-size: 13px; }
.ssa-noapp b { color: var(--title); }
.ssa-noic { width: 40px; height: 40px; flex: 0 0 40px; border-radius: 12px; display: grid; place-items: center; background: var(--surface-3); color: var(--title); }
.ssa-tog.dis { opacity: .5; }
.ssa-rpcst { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 12.5px; }
.ssa-glist { display: grid; gap: 6px; }
.ssa-game { display: flex; align-items: center; gap: 10px; padding: 7px 8px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line); }
.ssa-game.hid { opacity: .55; }
.ssa-gic { width: 36px; height: 36px; flex: 0 0 36px; border-radius: 9px; overflow: hidden; display: grid; place-items: center; background: var(--surface-3); color: var(--text-2); }
.ssa-gic img { width: 100%; height: 100%; object-fit: cover; }
.ssa-gtx { flex: 1; min-width: 0; display: grid; gap: 2px; text-align: left; }
.ssa-gtx b { color: var(--title); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ssa-gtx small { color: var(--text-3); font-size: 11.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ssa-gname { padding: 5px 8px; font-size: 13px; }
.ssa-plist { display: grid; gap: 4px; max-height: min(52vh, 460px); overflow-y: auto; }
.ssa-proc { display: flex; align-items: center; gap: 10px; padding: 7px 8px; border-radius: 9px; border: 1px solid transparent; background: none; color: var(--text); cursor: pointer; font: inherit; }
.ssa-proc:hover { background: var(--surface-2); border-color: var(--line-2); }
@media (max-width: 760px) {
  .ssa-edgrid { grid-template-columns: minmax(0, 1fr); }
  .ssa-side { position: static; order: -1; }
}
@media (max-width: 520px) {
  .ssa-2 { grid-template-columns: minmax(0, 1fr); }
  .ssa-body { padding: 12px; }
  .ssa .ssp-foot { flex-wrap: wrap; }
}
.umenu .ucsl { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------------------------------------------------------------- perguntas do site (dialog.js), por cima de tudo */

.dlg-ov { position: fixed; inset: 0; z-index: 98; display: grid; place-items: center; padding: 16px; background: color-mix(in srgb, var(--deep) 76%, transparent); animation: dlgIn .12s ease-out; }
.dlg { width: min(440px, 100%); max-height: 100%; overflow-y: auto; display: flex; flex-direction: column; gap: 12px; padding: 20px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line-2); box-shadow: var(--shadow); color: var(--text); font: 14px/1.5 var(--font); text-align: left; cursor: default; user-select: none; }
.dlg h3 { margin: 0; color: var(--title); font: 700 17px/1.3 var(--font-display); overflow-wrap: anywhere; }
.dlg p { margin: 0; color: var(--text-2); font-size: 14px; white-space: pre-line; overflow-wrap: anywhere; }
.dlg textarea.field { resize: vertical; min-height: 90px; }
.dlg-url { padding: 11px 13px; max-height: 132px; overflow-y: auto; border-radius: var(--radius-sm); background: var(--inset); border: 1px solid var(--line-2); color: var(--text-3); font-size: 13.5px; overflow-wrap: anywhere; user-select: text; }
.dlg-url b { color: var(--title); font-weight: 700; }
.dlg-c { display: flex; align-items: flex-start; gap: 10px; color: var(--text-2); font-size: 13.5px; cursor: pointer; overflow-wrap: anywhere; }
.dlg-c input { flex: 0 0 auto; width: 17px; height: 17px; margin: 1px 0 0; accent-color: var(--accent); color-scheme: dark; }
.dlg-c span { min-width: 0; }
.dlg-o { display: grid; gap: 8px; }
.dlg-op { display: grid; gap: 3px; padding: 12px 14px; text-align: left; font: inherit; color: var(--text); border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line-2); cursor: pointer; }
.dlg-op:hover { border-color: var(--line-3); background: var(--surface-3); }
.dlg-op:focus-visible { outline: 2px solid var(--primary-2); outline-offset: 2px; }
.dlg-op b { color: var(--title); font-size: 14px; }
.dlg-op.bad b { color: var(--danger-text); }
.dlg-op small { color: var(--text-3); font-size: 12.5px; }
.dlg-f { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 10px; margin-top: 6px; }
.dlg-f .btn { text-decoration: none; }
@keyframes dlgIn { from { opacity: 0; } to { opacity: 1; } }
@media (max-width: 760px) {
  .dlg-ov { padding: 0; place-items: end stretch; }
  .dlg { width: auto; max-height: 88dvh; border-radius: 18px 18px 0 0; border-width: 1px 0 0; padding: 20px 16px calc(16px + env(safe-area-inset-bottom) + var(--kb, 0px)); animation: dlgUp .18s ease-out; }
  .dlg .field { font-size: 16px; }
  .dlg-f .btn { flex: 1 1 130px; min-height: 46px; }
  .dlg-op { min-height: 54px; }
}
@keyframes dlgUp { from { transform: translateY(40px); } to { transform: none; } }
@media (prefers-reduced-motion: reduce) { .dlg-ov, .dlg { animation: none; } }
