/* ==========================================================================
   Selo 2.0 — estilos do site (Design System completo)
   Referência visual: inc/previa/prototipo/ (usa ESTE arquivo).  Brief: DESIGN.md · Resumo: CLAUDE.md seção 14.
   Camadas de cor:  BASE (neutros)  +  PRIMÁRIA (ciano Selo)  +  AMBIENTE (cores das fotos, via assets/ambiente.js)
   · ciano  (--pri)  = ação, link, ativo, foco, marca      · âmbar (--lar) = reconhecimento / destaque
   · coral  (--neg)  = percepção crítica, sempre discreta   · escuro = azul-marinho (não preto)
   Contraste: ciano e âmbar da marca são claros demais para texto → --pri-forte (fundo de botão), --link, --lar-txt, --neg-txt.
   Espaços em múltiplos de 4. Cantos: --raio-p 10 · --raio 14 · --raio-g 22 (cards) · --raio-x 28 (especiais).
   ========================================================================== */

/* ---------- 1. Tokens ---------- */
@property --amb-1 { syntax: '<color>'; inherits: true; initial-value: transparent; }
@property --amb-2 { syntax: '<color>'; inherits: true; initial-value: transparent; }
@property --amb-3 { syntax: '<color>'; inherits: true; initial-value: transparent; }

:root {
  --bg: #f6f7f9; --sup: #ffffff; --sup2: #f0f2f5; --sup3: #e4e7ec;
  --txt: #16181d; --suave: #636a77; --borda: #e7e9ed; --borda-leve: #f0f2f5;
  --pri: #19b7c9; --pri-forte: #087f92; --pri-hover: #066b7b; --pri-txt: #ffffff; --pri-leve: #ddf7fa; --link: #087f92;
  --lar: #f59e0b; --lar-leve: #fef3dc; --lar-txt: #8a5300;
  --neg: #e86a6a; --neg-leve: #fdeeee; --neg-txt: #b23f3f;
  --ok: #047857; --ok-leve: #e8f8f1; --erro: #c93b3b; --erro-leve: #fdeeee;
  /* Selos: cada selo tem um matiz (--h, vem do PHP); saturação e luz mudam por tema */
  --sf: 88%; --lf: 96%; --sb: 70%; --lb: 88%; --sn: 38%; --sa: 62%;
  --vidro: color-mix(in srgb, var(--bg) 72%, transparent);
  --vidro-forte: color-mix(in srgb, var(--sup) 82%, transparent);
  --sup-card: var(--sup);   /* cartões: opacos no claro; no escuro deixam passar um pouco da atmosfera */
  --raio-p: 10px; --raio: 14px; --raio-g: 22px; --raio-x: 28px;
  --e1: 4px; --e2: 8px; --e3: 12px; --e4: 16px; --e5: 20px; --e6: 24px; --e8: 32px; --e10: 40px; --e12: 48px; --e16: 64px;
  --sombra: 0 1px 2px rgba(22, 24, 29, .04), 0 4px 20px rgba(22, 24, 29, .05);
  --sombra-alta: 0 12px 40px rgba(22, 24, 29, .14);
  --rapido: 150ms; --medio: 220ms; --curva: cubic-bezier(.2, .8, .2, 1);
  --amb-tempo: 1400ms; --amb-forca: 1;
  --amb-1: hsla(187, 70%, 80%, .62); --amb-2: hsla(215, 50%, 85%, .52); --amb-3: hsla(38, 75%, 85%, .44);
  --amb-r1: 95% 68%; --amb-r2: 80% 62%; --amb-r3: 105% 72%;
  --brilho-forma: 0 26px 56px -22px; --brilho-forma-g: 0 40px 96px -32px;
  --larg-feed: 600px;
  --seg-baixo: env(safe-area-inset-bottom, 0px); --seg-topo: env(safe-area-inset-top, 0px);
  --fonte: Inter, "Segoe UI Variable Text", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color-scheme: light;
  transition: --amb-1 var(--amb-tempo) ease, --amb-2 calc(var(--amb-tempo) * 1.15) ease, --amb-3 calc(var(--amb-tempo) * 1.3) ease;
}
/* Modo escuro: AZUL-MARINHO. A atmosfera aparece mais (manchas maiores; cartões levemente translúcidos, sem desfoque).
   ATENÇÃO: os dois blocos abaixo (automático e escolhido em Configurações) precisam ficar iguais. */
@media (prefers-color-scheme: dark) {
  :root:not([data-tema="claro"]) {
    --bg: #0b1324; --sup: #121c33; --sup2: #1a2642; --sup3: #243252;
    --txt: #eef2f9; --suave: #a3afc6; --borda: #24314f; --borda-leve: #1a2642;
    --pri: #2cc3d4; --pri-forte: #0a8597; --pri-hover: #0c97ab; --pri-leve: #0e3346; --link: #5fd3e0;
    --lar: #f5ae33; --lar-leve: #33280f; --lar-txt: #f7c873;
    --neg: #ec8080; --neg-leve: #3a1f2b; --neg-txt: #f0a3a3;
    --ok: #4fd6a6; --ok-leve: #0f2f2e; --erro: #f08a8a; --erro-leve: #3a1f2b;
    --sf: 36%; --lf: 19%; --sb: 36%; --lb: 29%; --sn: 78%; --sa: 58%;
    --sombra: 0 1px 2px rgba(2, 6, 20, .3), 0 6px 24px rgba(2, 6, 20, .35);
    --sombra-alta: 0 12px 40px rgba(2, 6, 20, .6);
    --amb-1: hsla(190, 72%, 40%, .52); --amb-2: hsla(228, 64%, 46%, .46); --amb-3: hsla(270, 48%, 40%, .38);
    --amb-r1: 110% 80%; --amb-r2: 95% 75%; --amb-r3: 120% 80%;
    --sup-card: rgba(18, 28, 51, .8);
    --brilho-forma: 0 22px 64px -14px; --brilho-forma-g: 0 30px 100px -20px;
    color-scheme: dark;
  }
}
:root[data-tema="escuro"] {
  --bg: #0b1324; --sup: #121c33; --sup2: #1a2642; --sup3: #243252;
  --txt: #eef2f9; --suave: #a3afc6; --borda: #24314f; --borda-leve: #1a2642;
  --pri: #2cc3d4; --pri-forte: #0a8597; --pri-hover: #0c97ab; --pri-leve: #0e3346; --link: #5fd3e0;
  --lar: #f5ae33; --lar-leve: #33280f; --lar-txt: #f7c873;
  --neg: #ec8080; --neg-leve: #3a1f2b; --neg-txt: #f0a3a3;
  --ok: #4fd6a6; --ok-leve: #0f2f2e; --erro: #f08a8a; --erro-leve: #3a1f2b;
  --sf: 36%; --lf: 19%; --sb: 36%; --lb: 29%; --sn: 78%; --sa: 58%;
  --sombra: 0 1px 2px rgba(2, 6, 20, .3), 0 6px 24px rgba(2, 6, 20, .35);
  --sombra-alta: 0 12px 40px rgba(2, 6, 20, .6);
  --amb-1: hsla(190, 72%, 40%, .52); --amb-2: hsla(228, 64%, 46%, .46); --amb-3: hsla(270, 48%, 40%, .38);
  --amb-r1: 110% 80%; --amb-r2: 95% 75%; --amb-r3: 120% 80%;
  --sup-card: rgba(18, 28, 51, .8);
  --brilho-forma: 0 22px 64px -14px; --brilho-forma-g: 0 30px 100px -20px;
  color-scheme: dark;
}
@media (prefers-reduced-motion: reduce) { :root { transition: none; } *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; } }

/* ---------- 2. Base ---------- */
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; -webkit-tap-highlight-color: transparent; }
body { margin: 0; min-height: 100dvh; background: var(--bg); color: var(--txt); font: 15px/1.5 var(--fonte); -webkit-font-smoothing: antialiased; }
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }
button { font: inherit; color: inherit; }
img, video { max-width: 100%; display: block; }
h1, h2, h3 { margin: 0; }
p { margin: 0 0 12px; }
h1 { font-size: clamp(1.75rem, 1.5rem + 1vw, 2rem); font-weight: 800; line-height: 1.15; letter-spacing: -.025em; }
h2 { font-size: 1.25rem; font-weight: 700; line-height: 1.25; letter-spacing: -.015em; }
h3 { font-size: 1.0625rem; font-weight: 700; line-height: 1.3; margin: 0 0 12px; }
code { font: 12.5px ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; background: var(--sup2); padding: 1px 6px; border-radius: 6px; }
.suave { color: var(--suave); }
.centro { text-align: center; }
.perigo { color: var(--erro) !important; }
.micro { font-size: 12px; }
.sobrelinha { margin: 0; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--suave); }
.so-leitor { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.ico { width: 24px; height: 24px; flex-shrink: 0; }
.ico-p { width: 18px; height: 18px; }
:focus-visible { outline: 2px solid var(--pri); outline-offset: 2px; border-radius: 8px; }
::selection { background: color-mix(in srgb, var(--pri) 25%, transparent); }
.num { font-variant-numeric: tabular-nums; }
.so-desk { display: none !important; }
@media (min-width: 768px) { .so-desk { display: block !important; } .so-cel { display: none !important; } }

/* ---------- 3. Ambient Gradient (assets/ambiente.js grava --amb-1/2/3) ---------- */
.ambiente { position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: var(--amb-forca); transition: opacity .8s ease;
  background:
    radial-gradient(var(--amb-r1) at 8% -8%, var(--amb-1) 0%, transparent 70%),
    radial-gradient(var(--amb-r2) at 100% 12%, var(--amb-2) 0%, transparent 72%),
    radial-gradient(var(--amb-r3) at 55% 108%, var(--amb-3) 0%, transparent 70%); }
.app { position: relative; z-index: 1; min-height: 100dvh; }

/* ---------- 4. Botões ---------- */
/* Primário = ação principal (uma por tela) · padrão = neutro · .btn-t terciário · .btn-perigo raro e discreto */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 44px; padding: 0 18px; border-radius: var(--raio); border: 0; background: var(--sup2); color: var(--txt); font-size: 14px; font-weight: 650; cursor: pointer; white-space: nowrap; text-decoration: none !important; transition: background var(--rapido), transform var(--rapido), color var(--rapido), box-shadow var(--rapido); }
.btn:hover { background: var(--sup3); }
.btn:active:not(:disabled) { transform: scale(.97); }
.btn .ico { width: 20px; height: 20px; }
.btn-p { background: var(--pri-forte); color: var(--pri-txt); }
.btn-p:hover { background: var(--pri-hover); }
.btn-s { background: var(--lar); color: #16181d; }
.btn-s:hover { background: color-mix(in srgb, var(--lar) 88%, #000); }
.btn-t { background: none; color: var(--link); padding: 0 12px; }
.btn-t:hover { background: var(--pri-leve); }
.btn-borda { background: var(--sup-card); box-shadow: inset 0 0 0 1px var(--borda); }
.btn-borda:hover { background: var(--sup2); }
.btn-perigo { background: none; color: var(--neg-txt); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--neg) 45%, transparent); }
.btn-perigo:hover { background: var(--neg-leve); }
.btn-vidro { background: rgba(255, 255, 255, .22); color: #fff; backdrop-filter: blur(14px) saturate(1.6); -webkit-backdrop-filter: blur(14px) saturate(1.6); }
.btn-peq { height: 36px; padding: 0 14px; font-size: 13px; border-radius: 12px; }
.btn-g { height: 52px; padding: 0 24px; font-size: 16px; border-radius: 16px; }
.btn-largo { width: 100%; }
.btn:disabled { opacity: .4; cursor: not-allowed; }
.link-discreto { background: none; border: 0; padding: 0; color: var(--suave); font: inherit; font-size: 13px; font-weight: 650; cursor: pointer; }
.link-discreto:hover { color: var(--txt); }
.link-mais { font-size: 13px; font-weight: 650; color: var(--link); background: none; border: 0; padding: 0; cursor: pointer; }
.ico-btn { position: relative; display: inline-grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 50%; background: none; color: var(--txt); cursor: pointer; text-decoration: none !important; transition: background var(--rapido), transform var(--rapido); }
.ico-btn:hover { background: color-mix(in srgb, var(--txt) 6%, transparent); }
.ico-btn:active { transform: scale(.9); }
.ico-btn.ativo { color: var(--link); }
.ico-btn.vidro { background: var(--vidro-forte); backdrop-filter: blur(14px) saturate(1.6); -webkit-backdrop-filter: blur(14px) saturate(1.6); box-shadow: 0 0 0 1px color-mix(in srgb, var(--borda) 60%, transparent); }
.ico-perigo:hover { color: var(--erro); background: var(--erro-leve); }
.badge { position: absolute; top: 5px; right: 4px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: var(--lar); color: #16181d; box-shadow: 0 0 0 2px var(--sup); font-size: 10.5px; font-weight: 800; line-height: 18px; text-align: center; font-variant-numeric: tabular-nums; }
.ponto-novo { width: 8px; height: 8px; border-radius: 50%; background: var(--pri); flex-shrink: 0; }

/* ---------- 5. Campos ---------- */
input, textarea, select { font: inherit; font-size: 16px; color: var(--txt); background: var(--sup2); border: 1px solid transparent; border-radius: var(--raio); padding: 12px 14px; max-width: 100%; transition: border-color var(--rapido), box-shadow var(--rapido), background var(--rapido); }
@media (min-width: 768px) { input, textarea, select { font-size: 15px; } }
input::placeholder, textarea::placeholder { color: var(--suave); }
input:focus, textarea:focus, select:focus { outline: none; background: var(--sup); border-color: var(--pri); box-shadow: 0 0 0 4px color-mix(in srgb, var(--pri) 18%, transparent); }
input[type=checkbox], input[type=radio] { accent-color: var(--pri-forte); width: 18px; height: 18px; padding: 0; }
input[type=range] { padding: 0; background: none; border: 0; accent-color: var(--pri-forte); }
textarea { resize: vertical; line-height: 1.5; }
.campo { width: 100%; height: 48px; padding: 0 16px; }
textarea.campo { height: auto; min-height: 112px; padding: 14px 16px; }
.campo.invalido { border-color: var(--erro); box-shadow: 0 0 0 4px var(--erro-leve); }
.form { display: grid; gap: 16px; }
.form label, .rotulo { display: grid; gap: 6px; font-weight: 650; font-size: 13px; color: var(--txt); }
.form label input, .form label textarea, .form label select { font-weight: 400; width: 100%; }
.form label.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; font-size: 13.5px; color: var(--suave); }
.form label.check input { width: 18px; margin-top: 2px; flex-shrink: 0; }
.form.linha, .filtros { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 16px; }
.form.linha input:not([type=hidden]), .filtros input { flex: 1; min-width: 160px; }
.ajuda { font-size: 12px; color: var(--suave); font-weight: 400; }
.busca { position: relative; display: block; }
.busca .ico { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); width: 20px; height: 20px; color: var(--suave); pointer-events: none; }
.busca input { width: 100%; height: 48px; padding-left: 44px; border-radius: 999px; }
.chave { position: relative; width: 50px; height: 30px; flex-shrink: 0; }
.chave input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; margin: 0; cursor: pointer; z-index: 1; }
.chave span { position: absolute; inset: 0; border-radius: 999px; background: var(--sup3); transition: background var(--medio); }
.chave span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; box-shadow: 0 2px 6px rgba(0, 0, 0, .18); transition: transform var(--medio) var(--curva); }
.chave input:checked + span { background: var(--pri-forte); }
.chave input:checked + span::after { transform: translateX(20px); }
.chave input:focus-visible + span { outline: 2px solid var(--pri); outline-offset: 2px; }
.segmento { display: inline-flex; gap: 2px; padding: 4px; border-radius: 999px; background: var(--sup2); max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.segmento button, .segmento a { flex: 1 0 auto; display: inline-grid; place-items: center; height: 36px; padding: 0 14px; border: 0; border-radius: 999px; background: none; color: var(--suave); font-size: 13px; font-weight: 650; cursor: pointer; text-decoration: none !important; transition: background var(--medio), color var(--medio), box-shadow var(--medio); }
.segmento [aria-pressed="true"], .segmento [aria-current="page"] { background: var(--sup); color: var(--txt); box-shadow: 0 1px 3px rgba(22, 24, 29, .1); }
.segmento.largo { display: flex; width: 100%; }
.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 2px; }
.chips::-webkit-scrollbar { display: none; }
.chip-f { display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px; flex-shrink: 0; border-radius: 999px; border: 0; background: var(--sup-card); color: var(--txt); box-shadow: inset 0 0 0 1px var(--borda); font-size: 13px; font-weight: 650; cursor: pointer; text-decoration: none !important; }
.chip-f[aria-pressed="true"], .chip-f[aria-current="page"] { background: var(--txt); color: var(--bg); box-shadow: none; }
.etiqueta { display: inline-flex; align-items: center; gap: 4px; min-height: 22px; padding: 0 8px; border-radius: 999px; background: var(--sup2); color: var(--suave); font-size: 11.5px; font-weight: 650; vertical-align: middle; }
.etiqueta-pri { background: var(--pri-leve); color: var(--link); }
.etiqueta-lar { background: var(--lar-leve); color: var(--lar-txt); }
.etiqueta-neg { background: var(--neg-leve); color: var(--neg-txt); }

/* ---------- 6. SELO — componente proprietário ----------
   [emoji maior] [nome] · [contador]. Matiz próprio por selo (--h), borda discreta, raio total.
   Estados: normal · ativo (aria-pressed / .ativo = "eu reconheço você assim") · .selo-neg (percepção crítica, neutra). */
.selo { --h: 200; display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px 0 8px; flex-shrink: 0; border-radius: 999px; border: 1px solid hsl(var(--h) var(--sb) var(--lb)); background: hsl(var(--h) var(--sf) var(--lf)); color: var(--txt); font-size: 13px; font-weight: 650; line-height: 1; white-space: nowrap; text-decoration: none !important; transition: transform var(--rapido), background var(--medio), border-color var(--medio), box-shadow var(--medio); }
.selo .e { font-size: 18px; line-height: 1; }
.selo .n { color: hsl(var(--h) 40% var(--sn)); font-weight: 650; font-variant-numeric: tabular-nums; }
.selo .n::before { content: "·"; margin-right: 5px; opacity: .55; }
.selo .n:empty { display: none; }
button.selo { cursor: pointer; }
button.selo:hover { background: hsl(var(--h) var(--sf) calc(var(--lf) - 3%)); }
button.selo:active { transform: scale(.96); }
button.selo:disabled { cursor: default; opacity: .45; }
.selo.ativo, .selo[aria-pressed="true"] { background: hsl(var(--h) var(--sf) calc(var(--lf) - 6%)); border-color: hsl(var(--h) 65% var(--sa)); box-shadow: inset 0 0 0 1px hsl(var(--h) 65% var(--sa)); font-weight: 750; }
.selo-neg { border-color: var(--borda); background: var(--sup2); }
.selo-neg .n { color: var(--neg-txt); }
button.selo-neg:hover { background: var(--sup3); }
.selo-neg.ativo, .selo-neg[aria-pressed="true"] { background: var(--neg-leve); border-color: color-mix(in srgb, var(--neg) 55%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--neg) 55%, transparent); }
.selo-p { height: 26px; gap: 4px; padding: 0 9px 0 6px; font-size: 12px; }
.selo-p .e { font-size: 14px; }
.selo-g { height: 44px; gap: 8px; padding: 0 16px 0 12px; font-size: 15px; }
.selo-g .e { font-size: 22px; }
.selo-mais { --h: 220; border-style: dashed; background: none; color: var(--suave); }
.pop { animation: pop .22s ease-out; }
@keyframes pop { 45% { transform: scale(1.06); } }
.faisca { position: fixed; z-index: 90; width: 6px; height: 6px; margin: -3px 0 0 -3px; border-radius: 50%; pointer-events: none; animation: faisca .38s ease-out forwards; }
@keyframes faisca { to { transform: translate(var(--dx), var(--dy)) scale(.3); opacity: 0; } }
/* Selo antigo (.chip): painel admin e textos — mesmo desenho, neutro */
.chip { --h: 200; display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px 0 8px; border-radius: 999px; border: 1px solid var(--borda); background: var(--sup2); color: var(--txt); font: inherit; font-size: 13px; font-weight: 650; line-height: 1; white-space: nowrap; }
.chip > span { font-size: 18px; line-height: 1; }
.chip b { color: var(--suave); font-weight: 650; }
.chip b:empty { display: none; }
.chip b:not(:empty)::before { content: "·"; margin-right: 5px; opacity: .6; }
.chip-neg b { color: var(--neg-txt); }
.chip.grande { height: 40px; font-size: 14px; }
.ranking { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; }
/* Medalha: o selo como peça de identidade. Anel concêntrico = elemento gráfico da marca. */
.medalha { --h: 200; --t: 56px; display: inline-grid; place-items: center; width: var(--t); height: var(--t); flex-shrink: 0; border-radius: 50%; font-size: calc(var(--t) * .48); line-height: 1;
  background: radial-gradient(circle at 32% 26%, hsl(var(--h) var(--sf) calc(var(--lf) + 2%)), hsl(var(--h) var(--sf) calc(var(--lf) - 7%)));
  box-shadow: 0 0 0 3px var(--sup), 0 0 0 4.5px hsl(var(--h) 60% var(--sa)); }
.medalha-p { --t: 40px; box-shadow: 0 0 0 2px var(--sup), 0 0 0 3px hsl(var(--h) 55% var(--sa)); }
.medalha-g { --t: 84px; box-shadow: 0 0 0 4px var(--sup), 0 0 0 6px hsl(var(--h) 60% var(--sa)), 0 16px 32px -12px hsl(var(--h) 70% 50% / .45); }
.medalha.neg { background: var(--sup2); box-shadow: 0 0 0 2px var(--sup), 0 0 0 3px var(--borda); }

/* ---------- 7. Avatares ---------- */
.av { --t: 40px; width: var(--t); height: var(--t); border-radius: 50%; object-fit: cover; flex-shrink: 0; background: var(--sup2); }
.av-24 { --t: 24px; } .av-32 { --t: 32px; } .av-48 { --t: 48px; } .av-56 { --t: 56px; } .av-72 { --t: 72px; } .av-96 { --t: 96px; } .av-120 { --t: 120px; }
.pilha { display: inline-flex; flex-shrink: 0; }
.pilha .av { --t: 22px; box-shadow: 0 0 0 2px var(--sup); }
.pilha .av + .av { margin-left: -8px; }
.pilha .av-32 { --t: 32px; } .pilha .av-24 { --t: 24px; }
.verificado { display: inline-block; width: 16px; height: 16px; vertical-align: -2px; color: var(--pri-forte); }
/* Anel de novidade: só com significado (publicou nas últimas 24 h). Desenho = símbolo da marca. */
.anel-novo { position: relative; display: grid; place-items: center; width: 70px; height: 70px; border-radius: 50%; }
.anel-novo::before { content: ""; position: absolute; inset: 0; border-radius: 50%; background: conic-gradient(from 70deg, var(--pri) 0 300deg, transparent 0); -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 3px), #000 calc(100% - 2.5px)); mask: radial-gradient(farthest-side, transparent calc(100% - 3px), #000 calc(100% - 2.5px)); }
.anel-novo::after { content: ""; position: absolute; left: calc(83% - 5px); top: calc(17% - 5px); width: 10px; height: 10px; border-radius: 50%; background: var(--lar); box-shadow: 0 0 0 2px var(--bg); }
.anel-novo.visto::before { background: var(--borda); }
.anel-novo.visto::after { display: none; }
.anel-novo .av { --t: 60px; }
/* Autor (lista antiga: admin, editar perfil) */
.autor { display: flex; align-items: center; gap: 12px; color: var(--txt); min-width: 0; }
.autor:hover { text-decoration: none; }
.autor img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; flex-shrink: 0; background: var(--sup2); }
.autor > span:last-child { display: grid; min-width: 0; line-height: 1.3; }
.autor strong { font-weight: 650; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.autor small { color: var(--suave); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.avatar-g { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; flex-shrink: 0; background: var(--sup2); }

/* ---------- 8. Cards, seções e listas ---------- */
.cartao, .caixa { background: var(--sup-card); border-radius: var(--raio-g); box-shadow: var(--sombra); padding: var(--e5); }
.cartao + .cartao, .caixa + .caixa { margin-top: var(--e4); }
.caixa { margin-bottom: 16px; }
.caixa .caixa { box-shadow: none; padding: 0; background: none; }
.trilho > .cartao, .ds-grade > .cartao { margin-top: 0; }
.secao-titulo { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 28px 4px 12px; }
.secao-titulo h2 { font-size: 1.0625rem; }
.secao-titulo a { font-size: 13px; font-weight: 650; }
.linha { display: flex; align-items: center; gap: 12px; }
.linha-pessoa { display: flex; align-items: center; gap: 12px; padding: 10px 0; }
.linha-pessoa .quem { flex: 1; min-width: 0; display: grid; line-height: 1.3; color: var(--txt); text-decoration: none; }
.quem strong { font-weight: 650; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.quem small { color: var(--suave); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lista-pessoas { padding: 6px 16px; }
.lista-pessoas .linha-pessoa + .linha-pessoa { border-top: 1px solid var(--borda-leve); }
.paginas { display: flex; justify-content: space-between; gap: 10px; margin: 8px 0 24px; }
.paginas .btn:only-child { margin: 0 auto; }

/* ---------- 9. Estrutura: conteúdo, barra do topo, navegação ---------- */
.lateral { display: none; }
.conteudo { min-height: 100dvh; padding-bottom: calc(104px + var(--seg-baixo)); animation: tela .24s var(--curva); }
@keyframes tela { from { opacity: 0; transform: translateY(6px); } }
.visitante .conteudo { padding-bottom: 32px; }
.coluna, .feed.estreito { max-width: 620px; margin: 0 auto; padding: 0 12px; }
.coluna-larga { max-width: 1040px; margin: 0 auto; padding: 0 12px; }
.avisos { max-width: 620px; margin: 8px auto 0; padding: 0 12px; }
.aviso { margin: 0 0 12px; padding: 12px 16px; border-radius: var(--raio); font-size: 14px; font-weight: 550; animation: surge .25s var(--curva); }
.aviso-ok { background: var(--ok-leve); color: var(--ok); }
.aviso-erro { background: var(--erro-leve); color: var(--erro); }
.faixa-aviso { margin: 0 0 14px; padding: 12px 14px; border-radius: var(--raio); background: var(--sup2); color: var(--suave); font-size: 13.5px; }
.cab-pagina { display: flex; align-items: center; justify-content: space-between; margin: 8px 4px 16px; }
.cab-pagina h1 { margin: 0; }

.barra-app { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 4px; min-height: calc(60px + var(--seg-topo)); padding: var(--seg-topo) 8px 0; background: var(--vidro); backdrop-filter: blur(22px) saturate(1.7); -webkit-backdrop-filter: blur(22px) saturate(1.7); }
.barra-app h1 { flex: 1; min-width: 0; margin: 0; font-size: 1.1875rem; letter-spacing: -.02em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding-left: 8px; }
.barra-app .ico-btn + h1 { padding-left: 0; }
.barra-app .acoes { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.barra-app.sobre-foto { position: absolute; left: 0; right: 0; background: none; backdrop-filter: none; -webkit-backdrop-filter: none; }
.marca { display: inline-flex; align-items: center; gap: 8px; padding: 0 8px; color: var(--txt); font-weight: 800; font-size: 1.375rem; letter-spacing: -.045em; text-decoration: none !important; }
.marca svg { width: 30px; height: 30px; }
.marca-anel { stroke: var(--pri-forte); }
.marca-ponto { fill: var(--lar); }
/* Logo antigo (painel admin) */
.marca-selo { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 10px; background: var(--pri-forte); color: #fff; font-size: 15px; }

/* Navegação inferior (celular): flutuante, "Criar" em destaque */
.nav-inferior { position: fixed; z-index: 40; left: 12px; right: 12px; bottom: calc(10px + var(--seg-baixo)); max-width: 480px; margin: 0 auto; height: 66px; padding: 0 6px; display: grid; grid-template-columns: repeat(5, 1fr); align-items: center; border-radius: 24px; background: var(--vidro-forte); backdrop-filter: blur(24px) saturate(1.8); -webkit-backdrop-filter: blur(24px) saturate(1.8); box-shadow: 0 10px 34px rgba(22, 24, 29, .14), 0 0 0 1px color-mix(in srgb, var(--borda) 80%, transparent); }
.nav-inferior a { position: relative; display: grid; justify-items: center; align-content: center; gap: 3px; height: 100%; color: var(--suave); font-size: 10.5px; font-weight: 650; text-decoration: none !important; }
.nav-inferior a .ico { transition: transform var(--rapido); }
.nav-inferior a:active .ico { transform: scale(.88); }
.nav-inferior a.ativo { color: var(--txt); }
.nav-inferior a.ativo .ico { stroke-width: 2.2; }
.nav-inferior a.ativo::after { content: ""; position: absolute; bottom: 6px; width: 4px; height: 4px; border-radius: 50%; background: var(--pri); }
.nav-inferior .badge { top: 6px; right: calc(50% - 22px); }
.nav-inferior .av { --t: 26px; }
.nav-inferior a.ativo .av { box-shadow: 0 0 0 2px var(--sup), 0 0 0 3.5px var(--txt); }
.nav-inferior .nav-criar { width: 52px; height: 52px; justify-self: center; border-radius: 18px; background: var(--pri-forte); color: #fff; box-shadow: 0 8px 20px -6px color-mix(in srgb, var(--pri-forte) 70%, transparent); transition: transform var(--rapido), background var(--rapido); }
.nav-inferior .nav-criar:hover { background: var(--pri-hover); }
.nav-inferior .nav-criar .ico { width: 26px; height: 26px; stroke-width: 2.2; }
.pagina-chat .nav-inferior, .pagina-publicar .nav-inferior, .pagina-post .nav-inferior { display: none; }
.pagina-chat .conteudo, .pagina-publicar .conteudo, .pagina-post .conteudo { padding-bottom: calc(24px + var(--seg-baixo)); }

/* Tablet e computador: navegação lateral */
@media (min-width: 768px) {
  .nav-inferior { display: none; }
  .lateral { position: fixed; z-index: 30; inset: 0 auto 0 0; width: 88px; display: flex; flex-direction: column; gap: 4px; padding: 20px 14px; overflow-y: auto; }
  .lateral .marca { justify-content: center; padding: 6px 0 20px; }
  .lateral .marca span { display: none; }
  .lateral nav { display: grid; gap: 4px; }
  .lateral nav a { position: relative; display: flex; align-items: center; justify-content: center; gap: 14px; height: 52px; padding: 0 14px; border-radius: 16px; color: var(--txt); font-size: 15px; font-weight: 550; text-decoration: none !important; transition: background var(--rapido); }
  .lateral nav a span { display: none; }
  .lateral nav a:hover { background: color-mix(in srgb, var(--txt) 5%, transparent); }
  .lateral nav a.ativo { background: var(--sup-card); box-shadow: var(--sombra); font-weight: 750; }
  .lateral nav a.ativo .ico { stroke-width: 2.2; }
  .lateral nav .badge { top: 8px; right: 12px; }
  .lateral .btn-criar { margin: 16px 0 0; width: 100%; height: 52px; padding: 0; border-radius: 16px; flex-shrink: 0; }
  .lateral .btn-criar span { display: none; }
  .lateral .eu { margin-top: auto; display: flex; align-items: center; justify-content: center; gap: 12px; padding: 8px; border-radius: 16px; color: var(--txt); text-decoration: none !important; }
  .lateral .eu:hover { background: color-mix(in srgb, var(--txt) 5%, transparent); }
  .lateral .eu .quem { display: none; }
  .com-nav .conteudo { margin-left: 88px; padding-bottom: 48px; }
  .coluna, .coluna-larga, .feed.estreito, .avisos { padding: 0 24px; }
  .barra-app { padding: 0 16px; min-height: 72px; background: none; backdrop-filter: none; -webkit-backdrop-filter: none; position: static; }
  .barra-app h1 { font-size: 1.625rem; }
  .barra-app.so-cel-barra { display: none; }
  .visitante .barra-app { max-width: 1100px; margin: 0 auto; }
}
@media (min-width: 1180px) {
  .lateral { width: 264px; padding: 24px 20px; }
  .lateral .marca { justify-content: flex-start; padding: 6px 10px 24px; }
  .lateral .marca span { display: inline; }
  .lateral nav a { justify-content: flex-start; }
  .lateral nav a span { display: inline; }
  .lateral nav .badge { position: static; margin-left: auto; box-shadow: none; }
  .lateral .btn-criar span { display: inline; }
  .lateral .eu { justify-content: flex-start; }
  .lateral .eu .quem { display: grid; }
  .com-nav .conteudo { margin-left: 264px; }
}

/* ---------- 10. Folhas (bottom sheet no celular, janela no computador) ---------- */
.folha { position: fixed; z-index: 71; inset: auto 0 0 0; width: auto; max-width: none; max-height: 88dvh; margin: 0; overflow-y: auto; overscroll-behavior: contain; padding: 8px 20px calc(24px + var(--seg-baixo)); border: 0; border-radius: 28px 28px 0 0; background: var(--sup); color: var(--txt); box-shadow: 0 -10px 40px rgba(0, 0, 0, .16); }
.folha[open] { animation: subir .3s var(--curva); }
.folha::backdrop { background: rgba(11, 19, 36, .45); }
.folha:focus { outline: none; }
.folha-alca { width: 40px; height: 5px; margin: 0 auto 12px; border-radius: 5px; background: var(--sup3); }
.folha-topo { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 16px; }
.folha-topo > div { flex: 1; min-width: 0; }
.folha-topo h2 { font-size: 1.1875rem; }
.folha-topo p { margin: 2px 0 0; font-size: 13px; color: var(--suave); }
.folha-topo .ico-btn { margin: -6px -10px 0 0; }
.folha-rotulo { margin: 0 4px 10px; }
.folha-contatos { display: flex; gap: 14px; margin: 0 -20px; padding: 0 20px 14px; overflow-x: auto; scrollbar-width: none; }
.contato { display: grid; justify-items: center; gap: 6px; width: 68px; flex-shrink: 0; padding: 0; border: 0; background: none; color: var(--txt); font-size: 12px; cursor: pointer; }
.contato .av { transition: transform var(--rapido); }
.contato:active .av { transform: scale(.92); }
.contato span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.contato.enviado { color: var(--link); }
.contato.enviado .av { box-shadow: 0 0 0 2px var(--sup), 0 0 0 4px var(--pri); }
.folha-opcoes { display: grid; border-top: 1px solid var(--borda); padding-top: 6px; margin: 0 -8px; }
@keyframes subir { from { transform: translateY(100%); } }
@keyframes fade { from { opacity: 0; } }
@media (min-width: 768px) {
  .folha { inset: 0; width: min(480px, calc(100vw - 48px)); max-height: min(720px, 88dvh); height: fit-content; margin: auto; padding: 20px 24px 24px; border-radius: var(--raio-x); }
  .folha[open] { animation: janela .22s var(--curva); }
  .folha-alca { display: none; }
}
@keyframes janela { from { opacity: 0; transform: translateY(8px) scale(.98); } }

/* Menu "⋯" (denunciar / bloquear) — <details>, sem JavaScript */
.menu-mais { position: relative; flex: 0 0 auto; }
.menu-mais > summary { list-style: none; cursor: pointer; }
.menu-mais > summary::-webkit-details-marker { display: none; }
.menu-mais[open] > summary { background: var(--sup2); }
.menu-mais-lista { position: absolute; right: 0; top: calc(100% + 4px); z-index: 25; display: grid; min-width: 240px; padding: 6px; border-radius: 18px; background: var(--sup); box-shadow: var(--sombra-alta), 0 0 0 1px var(--borda); animation: menu .16s var(--curva); transform-origin: top right; }
.menu-mais-lista form { margin: 0; }
@keyframes menu { from { opacity: 0; transform: scale(.96); } }
.opcao { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 46px; padding: 0 12px; border: 0; border-radius: 12px; background: none; color: var(--txt); font-size: 14.5px; font-weight: 550; text-align: left; cursor: pointer; text-decoration: none !important; white-space: nowrap; }
.opcao:hover { background: var(--sup2); }
.opcao .ico { width: 20px; height: 20px; color: var(--suave); }
.opcao-perigo, .opcao-perigo .ico { color: var(--neg-txt); }

/* Toast: retorno pessoal e contextual */
.toast { position: fixed; z-index: 95; left: 50%; bottom: calc(92px + var(--seg-baixo)); display: flex; align-items: center; gap: 12px; width: max-content; max-width: calc(100vw - 32px); padding: 12px 18px; border-radius: 18px; background: var(--txt); color: var(--bg); font-size: 14px; font-weight: 550; box-shadow: 0 12px 32px rgba(0, 0, 0, .22); transform: translateX(-50%); animation: toast .26s var(--curva); }
.toast .medalha { --t: 34px; font-size: 17px; box-shadow: none; margin-left: -6px; }
@keyframes toast { from { opacity: 0; transform: translate(-50%, 12px); } }
.pagina-chat .toast { bottom: 96px; }
@media (min-width: 768px) { .toast { bottom: 28px; } }

/* ---------- 11. Estados: carregando, vazio, erro ---------- */
.esq { border-radius: 10px; background: linear-gradient(90deg, var(--sup2) 0%, var(--sup3) 50%, var(--sup2) 100%); background-size: 200% 100%; animation: brilho 1.3s ease-in-out infinite; }
@keyframes brilho { to { background-position: -200% 0; } }
.girando { width: 28px; height: 28px; animation: girar .9s linear infinite; }
@keyframes girar { to { transform: rotate(360deg); } }
.estado, .vazio { display: grid; justify-items: center; gap: 6px; padding: 48px 24px; text-align: center; color: var(--suave); }
.estado-arte { position: relative; display: grid; place-items: center; width: 112px; height: 112px; margin-bottom: 12px; }
.estado-arte svg.aneis { position: absolute; inset: 0; width: 100%; height: 100%; }
.estado-arte .ico { position: relative; width: 36px; height: 36px; color: var(--link); stroke-width: 1.6; }
.estado h2, .vazio h2 { color: var(--txt); font-size: 1.25rem; }
.estado p, .vazio p { max-width: 30em; margin: 0; }
.estado .btn, .vazio .btn { margin-top: 14px; }
.vazio > .ico { width: 32px; height: 32px; padding: 20px; box-sizing: content-box; border-radius: 50%; background: var(--pri-leve); color: var(--link); stroke-width: 1.6; margin-bottom: 12px; }
.surge { animation: surge .26s var(--curva) both; animation-delay: calc(var(--i, 0) * 45ms); }
@keyframes surge { from { opacity: 0; transform: translateY(10px); } }

/* ==========================================================================
   TELAS
   ========================================================================== */

/* ---------- Feed ---------- */
.historias { display: flex; gap: 12px; overflow-x: auto; scrollbar-width: none; padding: 8px 12px 4px; margin: 0 -12px 8px; }
.historias::-webkit-scrollbar { display: none; }
.historia { display: grid; justify-items: center; gap: 6px; width: 74px; flex-shrink: 0; padding: 0; border: 0; background: none; color: var(--txt); font-size: 12px; font-weight: 550; text-decoration: none !important; }
.historia > span:last-child { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.historia .mais { position: absolute; right: 2px; bottom: 2px; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--pri-forte); color: #fff; box-shadow: 0 0 0 2.5px var(--bg); }
.historia .mais .ico { width: 14px; height: 14px; stroke-width: 2.6; }
.layout-feed { display: block; }
.aux { display: none; }
@media (min-width: 1280px) {
  .layout-feed { display: grid; grid-template-columns: minmax(0, 600px) 320px; gap: 40px; justify-content: center; padding: 0 24px; }
  .layout-feed > .coluna { padding: 0; max-width: none; margin: 0; }
  .aux { display: block; position: sticky; top: 24px; align-self: start; }
}
.aux .cartao { padding: 18px; }
.aux h3 { font-size: 14px; margin-bottom: 10px; }
.aux .rodape-links { margin-top: 20px; padding: 0 6px; font-size: 12px; color: var(--suave); line-height: 1.8; }
.aux .rodape-links a { color: inherit; }
.mini-rep { display: grid; gap: 8px; margin-top: 14px; }
.mini-rep .linha { font-size: 14px; }
.mini-rep .linha .num { margin-left: auto; color: var(--suave); font-size: 13px; }

/* Cartão de publicação */
.post { position: relative; background: var(--sup-card); border-radius: var(--raio-g); box-shadow: var(--sombra); padding: 14px 0 6px; margin-bottom: 16px; }
.post-topo { display: flex; align-items: center; gap: 12px; padding: 0 6px 0 14px; }
.post-topo form { margin: 0; }
.post-topo .quem { flex: 1; min-width: 0; display: grid; line-height: 1.3; color: var(--txt); text-decoration: none; }
.post-topo .quem strong { font-size: 15px; }
.post-texto { padding: 0 16px; margin: 12px 0 0; white-space: normal; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 6; -webkit-box-orient: vertical; overflow: hidden; }
.detalhe .post-texto { -webkit-line-clamp: unset; display: block; }
.post-midia { position: relative; display: block; margin: 12px 10px 0; border-radius: 18px; overflow: hidden; background: var(--sup2); box-shadow: var(--brilho-forma) var(--brilho, transparent); transition: box-shadow 1.2s ease; }
.post-midia img { width: 100%; height: auto; max-height: min(80vh, 780px); object-fit: cover; transition: transform .6s var(--curva); }
.post-midia:hover img { transform: scale(1.012); }
.post-midia video { width: 100%; max-height: min(80vh, 780px); background: #000; }
.post-cartaz { margin: 12px 10px 0; padding: 40px 28px; border-radius: 18px; min-height: 220px; display: grid; place-items: center; text-align: center; color: var(--txt); text-decoration: none !important; font-size: clamp(1.25rem, 3.6vw, 1.5rem); font-weight: 750; line-height: 1.3; letter-spacing: -.015em; overflow-wrap: anywhere;
  background: radial-gradient(120% 90% at 0% 0%, hsl(var(--ch, 187) 70% 90% / .9), transparent 60%), radial-gradient(100% 80% at 100% 100%, hsl(calc(var(--ch, 187) + 40) 70% 92% / .9), transparent 60%), var(--sup2); }
.post-cartaz span { display: -webkit-box; -webkit-line-clamp: 9; -webkit-box-orient: vertical; overflow: hidden; }
:root[data-tema="escuro"] .post-cartaz { background: radial-gradient(120% 90% at 0% 0%, hsl(var(--ch, 187) 55% 28%), transparent 62%), radial-gradient(100% 80% at 100% 100%, hsl(calc(var(--ch, 187) + 40) 50% 26%), transparent 62%), var(--sup2); }
@media (prefers-color-scheme: dark) { :root:not([data-tema="claro"]) .post-cartaz { background: radial-gradient(120% 90% at 0% 0%, hsl(var(--ch, 187) 55% 28%), transparent 62%), radial-gradient(100% 80% at 100% 100%, hsl(calc(var(--ch, 187) + 40) 50% 26%), transparent 62%), var(--sup2); } }
.post-selos { display: flex; gap: 8px; padding: 14px 14px 0; overflow-x: auto; scrollbar-width: none; }
.post-selos::-webkit-scrollbar { display: none; }
.post-selos:empty { display: none; }
.post-reconhecido { display: flex; align-items: center; gap: 8px; margin: 12px 16px 0; padding: 0; border: 0; background: none; color: var(--suave); font-size: 13px; text-align: left; cursor: pointer; }
.post-reconhecido b { color: var(--txt); font-weight: 650; }
.post-acoes { display: flex; align-items: center; gap: 2px; padding: 10px 8px 0; }
.acao { display: inline-flex; align-items: center; gap: 6px; height: 40px; min-width: 44px; padding: 0 10px; justify-content: center; border: 0; border-radius: 999px; background: none; color: var(--txt); font-size: 14px; font-weight: 650; cursor: pointer; text-decoration: none !important; transition: background var(--rapido), transform var(--rapido); }
.acao:hover { background: var(--sup2); }
.acao:active { transform: scale(.94); }
.acao .ico { width: 22px; height: 22px; }
.acao-fim { margin-left: auto; color: var(--suave); }
.btn-selar { display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 16px 0 12px; margin-right: 4px; border: 0; border-radius: 999px; background: var(--pri-leve); color: var(--link); font-size: 14px; font-weight: 750; cursor: pointer; text-decoration: none !important; transition: background var(--medio), color var(--medio), transform var(--rapido); }
.btn-selar .ico { width: 22px; height: 22px; }
.btn-selar:hover { background: color-mix(in srgb, var(--pri-leve) 75%, var(--pri)); }
.btn-selar:active { transform: scale(.95); }
.btn-selar .marca-ponto { fill: var(--lar); }
.btn-selar.dei { background: var(--lar-leve); color: var(--lar-txt); }
@media (max-width: 480px) { .post { border-radius: 20px; } .post-midia, .post-cartaz { margin-left: 8px; margin-right: 8px; } }

/* ---------- Folha "Selar" ---------- */
.grade-selos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.cartao-selo { --h: 200; position: relative; display: flex; align-items: center; gap: 12px; min-height: 64px; padding: 12px; border-radius: 18px; border: 1px solid hsl(var(--h) var(--sb) var(--lb)); background: hsl(var(--h) var(--sf) var(--lf)); color: var(--txt); text-align: left; font-size: 14.5px; cursor: pointer; transition: transform var(--rapido), background var(--medio), box-shadow var(--medio), opacity var(--medio); }
.cartao-selo:hover { background: hsl(var(--h) var(--sf) calc(var(--lf) - 3%)); }
.cartao-selo:active { transform: scale(.97); }
.cartao-selo .e { font-size: 28px; line-height: 1; }
.cartao-selo strong { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.cartao-selo:disabled { opacity: .4; cursor: not-allowed; }
.cartao-selo[aria-pressed="true"] { background: hsl(var(--h) var(--sf) calc(var(--lf) - 7%)); box-shadow: inset 0 0 0 2px hsl(var(--h) 65% var(--sa)); }
.cartao-selo[aria-pressed="true"]::after { content: ""; position: absolute; top: 8px; right: 8px; width: 20px; height: 20px; border-radius: 50%; background: hsl(var(--h) 65% 42%) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 12.5 4 4 8-9'/%3E%3C/svg%3E") center / 14px no-repeat; animation: pop .22s ease-out; }
.cartao-selo.neg { border-color: var(--borda); background: var(--sup2); }
.cartao-selo.neg[aria-pressed="true"] { background: var(--neg-leve); box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--neg) 60%, transparent); }
.cartao-selo.neg[aria-pressed="true"]::after { background-color: var(--neg-txt); }
.criticos { margin-top: 16px; border-top: 1px solid var(--borda); padding-top: 4px; }
.criticos summary { display: flex; align-items: center; gap: 8px; min-height: 48px; cursor: pointer; list-style: none; font-size: 14px; font-weight: 650; color: var(--suave); }
.criticos summary::-webkit-details-marker { display: none; }
.criticos summary::after { content: ""; margin-left: auto; width: 8px; height: 8px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); transition: transform var(--medio); }
.criticos[open] summary::after { transform: rotate(-135deg); }
.criticos p { font-size: 13px; color: var(--suave); margin-bottom: 12px; }
.nota-publica { display: flex; gap: 8px; align-items: flex-start; margin: 16px 0 0; font-size: 12.5px; color: var(--suave); }
.nota-publica .ico { width: 16px; height: 16px; margin-top: 2px; }
.confirmacao { display: grid; justify-items: center; gap: 6px; padding: 12px 0 4px; text-align: center; animation: surge .26s var(--curva) both; }
.confirmacao .medalha { margin-bottom: 10px; animation: pop .3s ease-out; }
.confirmacao p { margin: 0; }
.confirmacao h2 { font-size: 1.375rem; }
.confirmacao .botoes { display: flex; gap: 8px; margin-top: 16px; width: 100%; }
.confirmacao .botoes .btn { flex: 1; }
.grupo-selo { padding: 12px 0; border-top: 1px solid var(--borda-leve); }
.grupo-selo:first-child { border-top: 0; }
.grupo-selo > .linha:first-child { margin-bottom: 8px; }
.grupo-selo > .linha:first-child strong { flex: 1; }
.grupo-selo .gente { display: grid; gap: 2px; }
.grupo-selo .gente a { display: flex; align-items: center; gap: 10px; padding: 6px 0; color: var(--txt); font-size: 14px; }
.grupo-selo .gente a small { color: var(--suave); }

/* ---------- Detalhe da publicação ---------- */
.detalhe { max-width: 620px; margin: 0 auto; padding: 0 12px; }
.detalhe-midia { position: relative; border-radius: var(--raio-g); overflow: hidden; background: var(--sup2); box-shadow: var(--brilho-forma-g) var(--brilho, transparent); transition: box-shadow 1.2s ease; }
.detalhe-midia img { width: 100%; height: auto; max-height: 82vh; object-fit: contain; margin: 0 auto; animation: fade .4s ease-out; }
.detalhe-midia video { width: 100%; max-height: 82vh; background: #000; }
.detalhe-midia .post-cartaz { margin: 0; min-height: 360px; border-radius: 0; }
.detalhe-info { padding: 20px 4px 0; }
.detalhe-info .post-topo { padding: 0; }
.detalhe-info .post-texto { padding: 0; margin-top: 14px; font-size: 16px; }
.detalhe-meta { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: 10px; font-size: 13px; color: var(--suave); }
.detalhe-meta span { display: inline-flex; align-items: center; gap: 4px; }
.detalhe-meta .ico { width: 15px; height: 15px; }
.detalhe .post-acoes { padding: 14px 0 0; margin-left: -6px; }
.detalhe .post-selos { padding: 0; flex-wrap: wrap; overflow: visible; }
.detalhe-lado .rolagem { padding-bottom: 8px; }
@media (min-width: 1024px) {
  .detalhe { max-width: 1120px; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(380px, .95fr); padding: 0; margin: 8px auto 0; background: var(--sup-card); border-radius: var(--raio-x); box-shadow: var(--sombra-alta); overflow: hidden; }
  .detalhe-midia { border-radius: 0; display: grid; place-items: center; height: min(calc(100dvh - 120px), 860px); box-shadow: none; background: #000; }
  .detalhe-midia img, .detalhe-midia video { max-height: 100%; height: 100%; object-fit: contain; }
  .detalhe-midia .post-cartaz { height: 100%; width: 100%; }
  .detalhe-lado { height: min(calc(100dvh - 120px), 860px); overflow-y: auto; padding: 4px 28px 24px; }
  .detalhe-info { padding-top: 24px; }
}

/* ---------- Perfil ---------- */
.perfil-topo { position: relative; }
.capa { position: relative; overflow: hidden; height: calc(220px + var(--seg-topo)); background: var(--pri-leve); -webkit-mask-image: linear-gradient(to bottom, #000 50%, transparent 100%); mask-image: linear-gradient(to bottom, #000 50%, transparent 100%); }
.capa img { width: 100%; height: 100%; object-fit: cover; animation: fade .5s ease-out; }
.capa.cor-propria { background: linear-gradient(135deg, color-mix(in srgb, var(--cor-perfil) 55%, var(--bg)), color-mix(in srgb, var(--cor-perfil) 20%, var(--bg))); }
.perfil-cartao { position: relative; margin: -84px 12px 0; padding: 0 20px 20px; border-radius: var(--raio-x); background: var(--sup-card); box-shadow: var(--sombra); text-align: center; }
.perfil-cartao .av-perfil { --t: 104px; margin: 0 auto -40px; transform: translateY(-50%); box-shadow: 0 0 0 5px var(--sup), 0 10px 30px -10px rgba(0, 0, 0, .3); }
.perfil-cartao h1 { font-size: 1.625rem; display: inline-flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px; overflow-wrap: anywhere; }
.perfil-user { color: var(--suave); font-size: 15px; overflow-wrap: anywhere; }
.perfil-user .privado { display: inline-flex; vertical-align: -2px; }
.perfil-user .privado .ico { width: 16px; height: 16px; }
.perfil-bio { max-width: 34em; margin: 12px auto 0; white-space: pre-line; overflow-wrap: anywhere; }
.perfil-meta { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 14px; margin-top: 10px; font-size: 13px; color: var(--suave); }
.perfil-meta span { display: inline-flex; align-items: center; gap: 4px; }
.perfil-meta .ico { width: 15px; height: 15px; }
.perfil-acoes { display: grid; grid-template-columns: 1fr 1fr auto auto; gap: 8px; margin-top: 18px; }
.perfil-acoes.dois { grid-template-columns: 1fr 1fr; }
.perfil-acoes form { margin: 0; display: contents; }
.perfil-acoes .ico-btn { width: 44px; height: 44px; border-radius: var(--raio); background: var(--sup2); }
.perfil-acoes .menu-mais > summary { border-radius: var(--raio); background: var(--sup2); }
.numeros { display: grid; grid-template-columns: repeat(4, 1fr); margin: 20px -8px 0; padding: 16px 0 0; border-top: 1px solid var(--borda); list-style: none; }
.numeros a, .numeros div { display: grid; padding: 4px 0; border-radius: 12px; color: var(--txt); text-decoration: none !important; }
.numeros a:hover { background: var(--sup2); }
.numeros b { font-size: 1.125rem; font-weight: 800; letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
.numeros span { font-size: 12px; color: var(--suave); }
.numeros .rep b { color: var(--lar-txt); }
.esq-col > .cartao { margin: 12px 12px 0; }
.dir-col { padding: 0 12px; }
/* Card de Reputação (proprietário): qualitativo antes de quantitativo */
.reputacao { padding: 22px 20px 20px; }
.rep-cab { display: flex; align-items: center; gap: 16px; margin-top: 12px; }
.rep-cab .medalha-g { --t: 72px; }
.rep-cab h2 { font-size: 1.375rem; margin-top: 2px; }
.rep-cab p { margin: 0; font-size: 13px; color: var(--suave); }
.rep-lista { display: grid; gap: 4px; margin-top: 18px; }
.rep-item { --h: 200; display: grid; grid-template-columns: 40px 1fr auto; align-items: center; column-gap: 12px; row-gap: 6px; padding: 8px 6px; border: 0; border-radius: 14px; background: none; color: var(--txt); text-align: left; text-decoration: none !important; }
a.rep-item:hover { background: var(--sup2); }
.rep-item .medalha { grid-row: span 2; }
.rep-item strong { font-size: 14.5px; }
.rep-item .num { font-size: 13px; color: var(--suave); }
.rep-barra { grid-column: 2 / 4; height: 6px; border-radius: 99px; background: var(--sup2); overflow: hidden; }
.rep-barra span { display: block; height: 100%; min-width: 3px; border-radius: 99px; background: hsl(var(--h) 65% var(--sa)); transform-origin: left; animation: crescer .7s var(--curva) both; animation-delay: calc(var(--i, 0) * 60ms + 120ms); }
.rep-item.neg .rep-barra span { background: var(--neg); }
@keyframes crescer { from { transform: scaleX(0); } }
.rep-pe { display: flex; align-items: center; gap: 10px; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--borda-leve); font-size: 13px; color: var(--suave); }
.rep-pe b { color: var(--txt); }
.rep-pe .link-mais { margin-left: auto; }
.rep-acao { margin-top: 14px; }
.rep-vazia { margin: 12px 0 0; color: var(--suave); }
.percepcao { display: flex; gap: 12px; align-items: flex-start; }
.percepcao .txt { flex: 1; font-size: 14px; }
.percepcao .txt p { color: var(--suave); font-size: 13px; margin: 4px 0 0; }
/* Abas */
.abas { position: sticky; top: calc(60px + var(--seg-topo)); z-index: 10; display: flex; margin: 20px 0 12px; background: var(--vidro); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border-bottom: 1px solid var(--borda); }
.perfil-pagina .abas { top: 0; }
.abas a { position: relative; flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 50px; color: var(--suave); font-size: 14px; font-weight: 650; text-decoration: none !important; transition: color var(--medio); }
.abas a .ico { width: 19px; height: 19px; }
.abas a[aria-current="page"] { color: var(--txt); }
.abas a[aria-current="page"]::after { content: ""; position: absolute; left: 20%; right: 20%; bottom: -1px; height: 2.5px; border-radius: 3px; background: var(--txt); }
@media (max-width: 430px) { .abas a .ico { display: none; } .abas a { font-size: 13.5px; } }
/* Grade de publicações */
.grade, .grade-posts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; }
.tile { position: relative; display: block; aspect-ratio: 3 / 4; border-radius: 12px; overflow: hidden; background: var(--sup2); color: #fff; text-decoration: none !important; }
.tile img, .tile video { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--curva); }
.tile:hover img { transform: scale(1.04); }
.tile-selo { position: absolute; left: 6px; bottom: 6px; display: inline-flex; align-items: center; gap: 3px; height: 22px; padding: 0 7px 0 5px; border-radius: 999px; background: rgba(22, 24, 29, .4); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); font-size: 11px; font-weight: 700; }
.tile-selo .ico { width: 14px; height: 14px; }
.tile-selo .marca-ponto { fill: var(--lar); }
.tile-tipo { position: absolute; top: 6px; right: 6px; filter: drop-shadow(0 1px 3px rgba(0, 0, 0, .5)); }
.tile-tipo .ico { width: 20px; height: 20px; fill: #fff; stroke: #fff; }
.tile-texto { display: grid; place-items: center; padding: 12px; color: var(--txt); background: var(--pri-leve); }
.tile-texto p { margin: 0; font-size: 12px; font-weight: 700; text-align: center; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 6; -webkit-box-orient: vertical; overflow: hidden; }
@media (max-width: 480px) { .grade, .grade-posts { gap: 3px; margin: 0 -8px; } .tile { border-radius: 8px; } }
@media (min-width: 1024px) {
  .perfil-pagina { max-width: 1120px; margin: 0 auto; padding: 24px 24px 0; }
  .perfil-pagina .capa { height: 280px; border-radius: var(--raio-x); -webkit-mask-image: none; mask-image: none; box-shadow: var(--brilho-forma-g) var(--brilho, transparent); }
  .perfil-pagina .barra-app.sobre-foto { left: 24px; right: 24px; top: 24px; padding: 12px; }
  .perfil-grade { display: grid; grid-template-columns: 360px minmax(0, 1fr); gap: 32px; align-items: start; }
  .perfil-cartao { margin: -96px 0 0 24px; }
  .esq-col > .cartao { margin: 16px 0 0 24px; }
  .dir-col { padding: 16px 0 0; }
  .perfil-grade .abas { position: static; margin-top: 0; background: none; backdrop-filter: none; -webkit-backdrop-filter: none; }
}

/* ---------- Meus SELos ---------- */
.selos-heroi { position: relative; overflow: hidden; padding: 28px 20px 24px; text-align: center; }
.selos-heroi .trio { display: flex; justify-content: center; align-items: flex-end; gap: 14px; margin: 14px 0 18px; }
.selos-heroi .trio .medalha { animation: surge .4s var(--curva) both; }
.selos-heroi .trio .medalha:nth-child(1) { --t: 60px; animation-delay: .08s; }
.selos-heroi .trio .medalha:nth-child(2) { --t: 92px; }
.selos-heroi .trio .medalha:nth-child(3) { --t: 60px; animation-delay: .14s; }
.selos-heroi h2 { font-size: 1.375rem; }
.selos-heroi p { color: var(--suave); margin: 4px 0 0; }
.selos-heroi .etiqueta-lar { margin-top: 12px; }
.recente { display: flex; align-items: center; gap: 12px; padding: 10px 0; }
.recente + .recente { border-top: 1px solid var(--borda-leve); }
.recente .txt { flex: 1; min-width: 0; font-size: 14px; line-height: 1.5; }
.recente .txt a { color: var(--txt); font-weight: 700; }
.recente .txt small { display: block; color: var(--suave); font-size: 12px; }
.miniatura { width: 44px; height: 56px; border-radius: 10px; object-fit: cover; flex-shrink: 0; background: var(--sup2); }
.passos { display: grid; gap: 12px; counter-reset: passo; margin: 0; padding: 0; list-style: none; }
.passos li { display: flex; gap: 12px; font-size: 14px; color: var(--suave); }
.passos li::before { counter-increment: passo; content: counter(passo); display: grid; place-items: center; width: 26px; height: 26px; flex-shrink: 0; border-radius: 50%; background: var(--pri-leve); color: var(--link); font-size: 13px; font-weight: 800; }
@media (min-width: 1024px) { .selos-pagina { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: start; } }

/* ---------- Atividades ---------- */
.pedidos { display: flex; align-items: center; gap: 12px; padding: 14px 16px; margin-bottom: 8px; color: var(--txt); text-decoration: none !important; }
.pedidos .quem { flex: 1; display: grid; }
.pedidos .badge { position: static; box-shadow: none; }
.pedido { display: flex; align-items: center; gap: 12px; padding: 10px 0; }
.pedido + .pedido { border-top: 1px solid var(--borda-leve); }
.pedido .quem { flex: 1; min-width: 0; display: grid; color: var(--txt); }
.pedido form { display: flex; gap: 6px; margin: 0; }
.grupo-tempo { margin: 22px 4px 8px; }
.notif { position: relative; display: flex; align-items: center; gap: 12px; padding: 12px; margin: 0 -4px 4px; border-radius: 18px; color: var(--txt); text-decoration: none !important; transition: background var(--rapido); }
a.notif:hover { background: color-mix(in srgb, var(--sup-card) 70%, transparent); }
.notif.nova { background: var(--sup-card); box-shadow: var(--sombra); }
.notif .avs { position: relative; width: 48px; height: 48px; flex-shrink: 0; }
.notif .avs .av { position: absolute; --t: 36px; }
.notif .avs .av:first-child { top: 0; left: 0; }
.notif .avs .av:nth-child(2) { right: 0; bottom: 0; box-shadow: 0 0 0 2.5px var(--sup); }
.notif .avs.um .av { --t: 48px; position: static; }
.notif .avs .marcador { position: absolute; right: -4px; bottom: -4px; display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--sup); box-shadow: 0 0 0 2px var(--sup); font-size: 14px; }
.notif .txt { flex: 1; min-width: 0; font-size: 14px; line-height: 1.5; }
.notif .txt b { font-weight: 700; }
.notif .txt .selo { vertical-align: middle; margin: 1px 0; }
.notif .txt small { display: block; color: var(--suave); font-size: 12px; margin-top: 2px; }
.notif .ponto-novo { position: absolute; left: -2px; top: 50%; margin-top: -4px; }

/* ---------- Mensagens ---------- */
.conversas { display: grid; gap: 2px; list-style: none; margin: 0; padding: 0; }
.conversa-item { display: flex; align-items: center; gap: 12px; padding: 10px 12px; margin: 0 -4px; border-radius: 18px; color: var(--txt); text-decoration: none !important; transition: background var(--rapido); }
.conversa-item:hover { background: var(--sup-card); box-shadow: var(--sombra); }
.conversa-item .quem { flex: 1; min-width: 0; display: grid; }
.conversa-item.nao-lida strong, .conversa-item.nao-lida small { color: var(--txt); font-weight: 750; }
.conversa-item time { align-self: flex-start; margin-top: 6px; font-size: 12px; color: var(--suave); white-space: nowrap; }
.conversa-item .badge { position: static; box-shadow: none; align-self: center; }

/* Conversa (bolhas montadas pelo app.js) */
.chat { display: flex; flex-direction: column; max-width: 720px; min-height: 100dvh; margin: 0 auto; }
.chat-topo { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 4px; min-height: calc(60px + var(--seg-topo)); padding: var(--seg-topo) 8px 0; background: var(--vidro); backdrop-filter: blur(22px) saturate(1.7); -webkit-backdrop-filter: blur(22px) saturate(1.7); }
.chat-topo .autor { flex: 1; min-width: 0; }
.chat-topo .autor img { width: 38px; height: 38px; }
.chat-apagar { margin: 0 0 0 auto; }
.chat-msgs { flex: 1; display: flex; flex-direction: column; gap: 3px; padding: 16px 12px; }
.chat-inicio { display: grid; justify-items: center; gap: 4px; padding: 16px 0 28px; text-align: center; }
.chat-inicio .avatar-g { width: 80px; height: 80px; margin-bottom: 6px; }
.chat-inicio strong { font-size: 17px; }
.chat-inicio .btn { margin-top: 10px; }
.bolha { max-width: min(78%, 460px); padding: 9px 14px; border-radius: 20px; background: var(--sup-card); box-shadow: var(--sombra); white-space: pre-wrap; overflow-wrap: anywhere; align-self: flex-start; font-size: 15px; line-height: 1.4; animation: surge .18s var(--curva); transition: transform var(--rapido); }
/* Minhas mensagens: paleta escolhida pela pessoa (claras, texto sempre escuro) — "não vista" → "vista" */
.bolha.minha { align-self: flex-end; background: var(--bolha-nao-vista, #ffdcb8); color: #1b1f24; box-shadow: none; transition: background-color .4s, transform var(--rapido); }
.bolha.minha.vista { background: var(--bolha-vista, #cfe6ff); }
.bolha.minha a { color: inherit; text-decoration: underline; }
.bolha.apagada, .bolha.minha.apagada { background: none; box-shadow: inset 0 0 0 1px var(--borda); color: var(--suave); font-style: italic; font-size: 14px; }
.bolha.pressionada { transform: scale(.96); }
@media (pointer: coarse) { .bolha, .bolha img { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; } }
.bolha + .bolha:not(.minha), .bolha.minha + .bolha.minha { margin-top: 0; }
.bolha:not(.minha) + .bolha.minha, .bolha.minha + .bolha:not(.minha) { margin-top: 10px; }
.bolha.so-emoji, .bolha.minha.so-emoji { background: none; box-shadow: none; padding: 0 2px; font-size: 42px; line-height: 1.15; }
.bolha-foto { padding: 0; overflow: hidden; border-radius: 18px; width: min(240px, 70vw); }
.bolha-foto img { display: block; width: 100%; height: auto; max-height: 360px; object-fit: cover; cursor: zoom-in; background: var(--sup3); }
.bolha-foto p { margin: 0; padding: 8px 14px; }
.bolha-audio { display: flex; align-items: center; gap: 10px; padding: 6px 14px 6px 6px; width: min(260px, 72vw); }
.audio-play { display: grid; place-items: center; width: 34px; height: 34px; flex-shrink: 0; padding: 0; border: 0; border-radius: 50%; background: var(--sup2); color: var(--txt); cursor: pointer; }
.bolha-audio.minha .audio-play { background: rgba(255, 255, 255, .92); color: #1b1f24; }
.audio-play .ico { width: 18px; height: 18px; }
.audio-trilha { position: relative; flex: 1; height: 26px; cursor: pointer;
  background: repeating-linear-gradient(90deg, color-mix(in srgb, currentColor 35%, transparent) 0 2px, transparent 2px 5px);
  -webkit-mask: linear-gradient(transparent 30%, #000 30% 70%, transparent 70%); mask: linear-gradient(transparent 30%, #000 30% 70%, transparent 70%); }
.audio-trilha span { position: absolute; inset: 0 auto 0 0; width: 0; background: repeating-linear-gradient(90deg, currentColor 0 2px, transparent 2px 5px); }
.audio-tempo { font-size: 12px; font-variant-numeric: tabular-nums; min-width: 32px; text-align: right; }
.chat-status { align-self: flex-end; margin: 2px 6px 0; font-size: 11.5px; color: var(--suave); }
.chat-status.visto { color: var(--link); font-weight: 650; }
.chat-form { position: sticky; bottom: 0; padding: 8px 12px calc(10px + var(--seg-baixo)); background: var(--vidro); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); }
.chat-form.enviando { opacity: .6; pointer-events: none; }
.chat-barra, .chat-gravando { display: flex; align-items: flex-end; gap: 2px; min-height: 50px; padding: 4px; border-radius: 26px; background: var(--sup); box-shadow: var(--sombra); }
.chat-barra .ico-btn { width: 42px; height: 42px; flex-shrink: 0; }
.chat-barra .ico-btn.ativo { color: var(--lar-txt); }
.chat-form textarea { flex: 1; min-width: 0; min-height: 42px; max-height: 140px; padding: 10px 6px; border: 0; border-radius: 0; background: none; box-shadow: none; resize: none; line-height: 1.4; }
.chat-form textarea:focus { background: none; box-shadow: none; }
.chat-enviar { height: 42px; padding: 0 16px; border: 0; border-radius: 21px; background: var(--pri-forte); color: #fff; font: inherit; font-weight: 700; font-size: 14px; cursor: pointer; }
.chat-enviar:hover { background: var(--pri-hover); }
.chat-previa { position: relative; display: inline-block; margin: 0 0 8px 4px; }
.chat-previa img { display: block; max-height: 140px; max-width: 200px; border-radius: 14px; }
.chat-previa .ico-btn { position: absolute; top: 4px; right: 4px; width: 28px; height: 28px; background: rgba(0, 0, 0, .6); color: #fff; }
.chat-previa .ico-btn .ico { width: 16px; height: 16px; }
.chat-gravando { align-items: center; gap: 10px; padding: 4px 4px 4px 2px; }
.rec-ponto { width: 10px; height: 10px; border-radius: 50%; background: var(--neg); animation: piscar 1s infinite; }
@keyframes piscar { 50% { opacity: .2; } }
.rec-tempo { font-weight: 700; font-variant-numeric: tabular-nums; }
.rec-rotulo { flex: 1; font-size: 13px; }
.rec-enviar { display: grid; place-items: center; width: 42px; height: 42px; padding: 0; border: 0; border-radius: 50%; background: var(--pri-forte); color: var(--pri-txt); cursor: pointer; }
.rec-enviar .ico { width: 20px; height: 20px; }
.emoji-painel { margin-bottom: 8px; border-radius: var(--raio-g); background: var(--sup); box-shadow: var(--sombra); overflow: hidden; }
.emoji-abas { display: flex; gap: 2px; padding: 6px; border-bottom: 1px solid var(--borda); overflow-x: auto; scrollbar-width: none; }
.emoji-abas button { flex-shrink: 0; width: 38px; height: 34px; padding: 0; border: 0; border-radius: 8px; background: none; font-size: 20px; cursor: pointer; filter: grayscale(.7); opacity: .7; }
.emoji-abas button.ativo, .emoji-abas button:hover { background: var(--sup2); filter: none; opacity: 1; }
.emoji-grade { display: grid; grid-template-columns: repeat(auto-fill, minmax(40px, 1fr)); height: 216px; padding: 6px; overflow-y: auto; overscroll-behavior: contain; align-content: start; }
.emoji { height: 42px; padding: 0; border: 0; border-radius: 8px; background: none; font-size: 26px; line-height: 1; cursor: pointer; transition: transform .1s; }
.emoji:hover { background: var(--sup2); }
.emoji:active { transform: scale(1.25); }
.emoji-vazio { grid-column: 1 / -1; text-align: center; padding: 24px 0; font-size: 13px; }
.visor { width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: rgba(0, 0, 0, .92); }
.visor[open] { display: grid; place-items: center; }
.visor::backdrop { background: transparent; }
.visor img { max-width: 100%; max-height: 100dvh; object-fit: contain; }
.visor .ico-btn { position: fixed; top: calc(12px + var(--seg-topo)); right: 12px; color: #fff; background: rgba(255, 255, 255, .12); }
#folha-msg .folha-opcoes { border-top: 0; padding-top: 0; }

/* ---------- Criar publicação (editor de foto) ---------- */
.criar { max-width: 620px; margin: 0 auto; padding: 0 16px; }
.upload input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.upload-area { display: grid; place-items: center; min-height: 260px; padding: 24px; border: 1.5px dashed var(--borda); border-radius: var(--raio-g); background: var(--sup-card); cursor: pointer; overflow: hidden; color: var(--suave); text-align: center; transition: border-color var(--rapido), background var(--rapido); }
.upload:focus-within .upload-area, .upload-area:hover { border-color: var(--pri); background: var(--pri-leve); color: var(--link); }
.upload-area img, .upload-area video { max-height: 460px; width: 100%; object-fit: contain; border-radius: var(--raio); }
.upload[hidden] { display: none; }
.upload-txt { display: grid; justify-items: center; gap: 6px; }
.upload-txt .ico { width: 40px; height: 40px; stroke-width: 1.5; }
.upload-txt b { color: var(--txt); font-size: 16px; }
.upload-txt small { font-weight: 400; }
.editor { display: grid; gap: 14px; }
.editor[hidden] { display: none; }
.editor-palco { display: grid; place-items: center; padding: 12px; border-radius: var(--raio-g); background: var(--sup-card); box-shadow: var(--brilho-forma-g) var(--brilho, transparent); transition: box-shadow 1.2s ease; }
.editor-quadro { --r: 3 / 4; --rn: .75; position: relative; overflow: hidden; width: min(100%, calc(62vh * var(--rn))); aspect-ratio: var(--r); border-radius: 12px; background: #000; touch-action: none; cursor: grab; user-select: none; -webkit-user-select: none; }
.editor-quadro[data-proporcao="9:16"] { --r: 9 / 16; --rn: .5625; }
.editor-quadro.arrastando { cursor: grabbing; }
.editor-img { position: absolute; top: 0; left: 0; max-width: none; transform-origin: 0 0; pointer-events: none; will-change: transform; }
.editor-grade { position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity .2s;
  background: linear-gradient(to right, transparent calc(33.33% - .5px), rgba(255,255,255,.55) calc(33.33% - .5px), rgba(255,255,255,.55) calc(33.33% + .5px), transparent calc(33.33% + .5px), transparent calc(66.66% - .5px), rgba(255,255,255,.55) calc(66.66% - .5px), rgba(255,255,255,.55) calc(66.66% + .5px), transparent calc(66.66% + .5px)),
              linear-gradient(to bottom, transparent calc(33.33% - .5px), rgba(255,255,255,.55) calc(33.33% - .5px), rgba(255,255,255,.55) calc(33.33% + .5px), transparent calc(33.33% + .5px), transparent calc(66.66% - .5px), rgba(255,255,255,.55) calc(66.66% - .5px), rgba(255,255,255,.55) calc(66.66% + .5px), transparent calc(66.66% + .5px)); }
.editor-quadro.arrastando .editor-grade { opacity: 1; }
.editor-ferramentas { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; }
.editor-proporcoes { display: flex; gap: 4px; padding: 4px; border-radius: 999px; background: var(--sup2); }
.prop { display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 14px; border: 0; border-radius: 999px; background: none; color: var(--suave); font: inherit; font-size: 13px; font-weight: 650; cursor: pointer; }
.prop:hover { color: var(--txt); }
.prop.ativo { background: var(--sup); color: var(--txt); box-shadow: 0 1px 3px rgba(22, 24, 29, .1); }
.prop-forma { display: block; height: 16px; border: 1.8px solid currentColor; border-radius: 3px; }
.prop-trocar { color: var(--link); }
.editor-zoom { display: flex !important; align-items: center; gap: 10px !important; flex: 1; min-width: 180px; }
.editor-zoom span { font-size: 13px; }
.editor-zoom input { flex: 1; }
.editor-dica { width: 100%; margin: -4px 0 0; font-size: 12px; }
.editor-filtros, .filtros-lista { display: flex; gap: 10px; overflow-x: auto; padding: 4px 2px 6px; scrollbar-width: thin; scroll-snap-type: x proximity; }
.filtro { display: grid; gap: 6px; justify-items: center; flex-shrink: 0; width: 72px; padding: 0; border: 0; background: none; color: var(--suave); font: inherit; font-size: 12px; font-weight: 650; cursor: pointer; scroll-snap-align: start; }
.filtro img { width: 72px; height: 72px; object-fit: cover; border-radius: 14px; background: var(--sup2); transition: box-shadow var(--rapido), transform var(--rapido); }
.filtro:active img { transform: scale(.94); }
.filtro.ativo, .filtro[aria-pressed="true"] { color: var(--txt); }
.filtro.ativo img, .filtro[aria-pressed="true"] img { box-shadow: 0 0 0 2px var(--sup), 0 0 0 4px var(--pri); }
.atmosfera { display: flex; align-items: center; gap: 12px; padding: 14px 16px; }
.atmosfera .cores { display: flex; }
.atmosfera .cores i { width: 26px; height: 26px; border-radius: 50%; background: var(--sup2); box-shadow: 0 0 0 2px var(--sup); transition: background .8s; }
.atmosfera .cores i + i { margin-left: -6px; }
.atmosfera .txt { flex: 1; font-size: 13px; color: var(--suave); line-height: 1.4; }
.atmosfera .txt b { display: block; color: var(--txt); font-size: 14px; }
.contador { margin: 4px 0 0; text-align: right; font-size: 12px; color: var(--suave); font-weight: 400; }

/* ---------- Explorar ---------- */
.explorar-busca { position: sticky; top: 0; z-index: 20; padding: calc(10px + var(--seg-topo)) 12px 10px; margin: 0 -12px; background: var(--vidro); backdrop-filter: blur(22px) saturate(1.7); -webkit-backdrop-filter: blur(22px) saturate(1.7); }
.trilho { display: flex; gap: 12px; overflow-x: auto; scrollbar-width: none; padding: 4px 12px 8px; margin: 0 -12px; scroll-snap-type: x mandatory; scroll-padding-inline: 12px; }
.trilho::-webkit-scrollbar { display: none; }
.trilho > * { scroll-snap-align: start; flex-shrink: 0; }
.cartao-alta { --h: 200; display: grid; justify-items: start; gap: 10px; width: 150px; padding: 16px; border-radius: var(--raio-g); background: linear-gradient(160deg, hsl(var(--h) var(--sf) var(--lf)), var(--sup-card) 70%); box-shadow: var(--sombra); color: var(--txt); }
.cartao-alta strong { font-size: 15px; }
.cartao-alta small { display: flex; align-items: center; gap: 4px; color: var(--ok); font-size: 12px; font-weight: 700; }
.cartao-alta small .ico { width: 14px; height: 14px; }
.cartao-pessoa { width: 168px; padding: 0 0 14px; border-radius: var(--raio-g); background: var(--sup-card); box-shadow: var(--sombra); overflow: hidden; text-align: center; color: var(--txt); }
.cartao-pessoa .faixa-foto { display: block; height: 64px; background: var(--pri-leve) center / cover; }
.cartao-pessoa .av { --t: 64px; margin: -32px auto 0; box-shadow: 0 0 0 3px var(--sup); }
.cartao-pessoa > a { color: var(--txt); text-decoration: none !important; }
.cartao-pessoa strong { display: block; margin-top: 8px; padding: 0 10px; font-size: 14.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cartao-pessoa .selo { margin: 8px 0 12px; }
.cartao-pessoa .sem-selo { display: block; margin: 8px 0 12px; font-size: 12px; color: var(--suave); }
.mosaico { display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: 132px; grid-auto-flow: dense; gap: 4px; }
.mosaico .tile { aspect-ratio: auto; }
.mosaico .alto { grid-row: span 2; }
.mosaico .grande { grid-row: span 2; grid-column: span 2; }
@media (min-width: 768px) { .mosaico { grid-template-columns: repeat(4, 1fr); grid-auto-rows: 170px; gap: 8px; } .mosaico .tile { border-radius: 14px; } .explorar-busca { position: static; background: none; backdrop-filter: none; -webkit-backdrop-filter: none; padding-top: 16px; } }
@media (min-width: 1180px) { .mosaico { grid-template-columns: repeat(5, 1fr); } }

/* ---------- Configurações (editar-perfil.php) ---------- */
.grupo-config { background: var(--sup-card); border-radius: var(--raio-g); box-shadow: var(--sombra); overflow: hidden; }
.grupo-titulo { margin: 24px 8px 8px; }
.linha-config { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 60px; padding: 10px 16px; border: 0; border-top: 1px solid var(--borda-leve); background: none; color: var(--txt); font-size: 15px; text-align: left; text-decoration: none !important; cursor: pointer; }
.linha-config:first-child { border-top: 0; }
button.linha-config:hover, a.linha-config:hover { background: var(--sup2); }
.linha-config .ic { display: grid; place-items: center; width: 34px; height: 34px; flex-shrink: 0; border-radius: 11px; background: var(--sup2); color: var(--txt); }
.linha-config .ic .ico { width: 19px; height: 19px; }
.linha-config .txt { flex: 1; min-width: 0; display: grid; font-weight: 550; }
.linha-config .txt small { color: var(--suave); font-size: 12.5px; line-height: 1.35; font-weight: 400; }
.linha-config .valor { color: var(--suave); font-size: 14px; }
.linha-config .seta { width: 18px; height: 18px; color: var(--suave); }
.linha-config.bloco { display: grid; gap: 12px; cursor: default; }
.linha-config.critica { color: var(--neg-txt); }
.linha-config.critica .ic { background: var(--neg-leve); color: var(--neg-txt); }
.config-corpo { padding: 16px; }
.config-corpo + .config-corpo { border-top: 1px solid var(--borda-leve); }
.amostra-amb { position: relative; height: 92px; border-radius: 16px; overflow: hidden; background: var(--bg); box-shadow: inset 0 0 0 1px var(--borda); }
.amostra-amb::before { content: ""; position: absolute; inset: 0; opacity: var(--amb-forca); transition: opacity .6s; background: radial-gradient(80% 90% at 0% 0%, var(--amb-1), transparent 70%), radial-gradient(70% 80% at 100% 20%, var(--amb-2), transparent 72%), radial-gradient(90% 80% at 50% 120%, var(--amb-3), transparent 70%); }
.amostra-amb span { position: absolute; left: 16px; right: 16px; bottom: 14px; height: 38px; border-radius: 12px; background: var(--sup); box-shadow: var(--sombra); }
/* Escolher a capa do perfil (Automática · Do aparelho · fotos publicadas) */
.capa-escolha { display: grid; gap: 10px; }
.rotulo-capa { font-weight: 650; font-size: 13px; }
.capa-previa { aspect-ratio: 16 / 6; border-radius: 16px; overflow: hidden; background: var(--pri-leve); }
.capa-previa img { width: 100%; height: 100%; object-fit: cover; }
.capas { display: grid; grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: 8px; }
.form label.capa-op { position: relative; display: grid; place-items: center; aspect-ratio: 1; border-radius: 12px; overflow: hidden; background: var(--sup2); color: var(--suave); font-size: 12px; font-weight: 650; text-align: center; cursor: pointer; transition: box-shadow var(--rapido); }
.capa-op input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; padding: 0; opacity: 0; cursor: pointer; }
.capa-op img { width: 100%; height: 100%; object-fit: cover; }
.capa-texto span { display: grid; justify-items: center; gap: 2px; padding: 4px; line-height: 1.2; }
.capa-texto small { font-size: 10.5px; font-weight: 500; }
.capa-texto .ico { width: 22px; height: 22px; }
.capa-op:has(input:checked), .capa-op.escolhida { box-shadow: 0 0 0 2px var(--sup), 0 0 0 4px var(--pri); color: var(--txt); }
.capa-op:has(input:focus-visible) { outline: 2px solid var(--pri); outline-offset: 2px; }
.avatar-editar { display: flex; align-items: center; gap: 16px; }
.avatar-editar .avatar-g { width: 64px; height: 64px; }
.avatar-editar .btn { margin-left: auto; }
.barra-uso { height: 6px; background: var(--sup2); border-radius: 99px; overflow: hidden; }
.barra-uso span { display: block; height: 100%; background: var(--pri); border-radius: 99px; }
.barra-uso.alerta span { background: var(--lar); }
.cores { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.cores legend { font-weight: 650; font-size: 13px; margin-bottom: 8px; padding: 0; }
.form .cores label.cor { display: block; position: relative; width: 32px; height: 32px; cursor: pointer; }
.cor input[type=radio] { position: absolute; opacity: 0; inset: 0; margin: 0; width: 100%; height: 100%; cursor: pointer; }
.cor-custom input[type=radio] { pointer-events: none; }
.cor span, .cor input[type=color] { display: block; width: 100%; height: 100%; padding: 0; border-radius: 50%; background: var(--c); box-shadow: 0 0 0 2px var(--sup), 0 0 0 3px var(--borda); transition: box-shadow .15s, transform .1s; }
.cor-padrao span { background: var(--pri-leve); }
.cor input[type=color] { border: 0; cursor: pointer; background: conic-gradient(red, yellow, lime, cyan, blue, magenta, red); }
.cor input[type=color]::-webkit-color-swatch-wrapper { padding: 3px; }
.cor input[type=color]::-webkit-color-swatch { border: 0; border-radius: 50%; }
.cor input[type=color]::-moz-color-swatch { border: 0; border-radius: 50%; }
.cor:hover span, .cor:hover input[type=color] { transform: scale(1.08); }
.cor input[type=radio]:checked ~ span, .cor input[type=radio]:checked ~ input[type=color] { box-shadow: 0 0 0 2px var(--sup), 0 0 0 4px var(--txt); }
.cor input[type=radio]:focus-visible ~ span { outline: 2px solid var(--pri); outline-offset: 4px; }
.temas-chat { border: 0; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); gap: 8px; }
.temas-chat legend { font-weight: 650; font-size: 13px; margin-bottom: 4px; padding: 0; }
.temas-chat .dica { grid-column: 1 / -1; margin: 0 0 4px; font-size: 13px; font-weight: 400; }
.form .temas-chat label.tema-chat { display: block; position: relative; font-weight: 400; cursor: pointer; }
.tema-chat input { position: absolute; opacity: 0; inset: 0; margin: 0; width: 100%; height: 100%; cursor: pointer; }
.tema-caixa { display: grid; gap: 4px; padding: 10px; border-radius: var(--raio); background: var(--sup2); transition: box-shadow .15s; }
.tema-caixa i { justify-self: end; padding: 3px 10px; border-radius: 12px; font-style: normal; font-size: 12px; color: #1b1f24; background: var(--c); }
.tema-caixa small { margin-top: 2px; color: var(--suave); font-size: 12px; }
.tema-chat input:checked + .tema-caixa { box-shadow: inset 0 0 0 2px var(--txt); }
.tema-chat input:focus-visible + .tema-caixa { outline: 2px solid var(--pri); outline-offset: 2px; }
.opcoes-lista { border: 0; padding: 0; margin: 0; display: grid; gap: 4px; }
.opcoes-lista legend { font-weight: 650; font-size: 13px; padding: 0; margin-bottom: 8px; }
.form .opcoes-lista label.check { align-items: center; min-height: 48px; padding: 0 14px; border-radius: var(--raio); background: var(--sup2); color: var(--txt); font-size: 15px; cursor: pointer; }
.form .opcoes-lista label.check input { margin: 0; }
.form-acoes { display: flex; flex-wrap: wrap; gap: 8px; }
.zona-perigo summary { cursor: pointer; font-weight: 650; color: var(--neg-txt); min-height: 44px; display: flex; align-items: center; }
.zona-perigo[open] summary { margin-bottom: 8px; }

/* ---------- Visitante: página inicial, entrar/cadastro, textos legais ---------- */
.hero { display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; align-items: center; max-width: 1100px; margin: 0 auto; padding: 40px 24px; }
.hero h1 { font-size: clamp(2.1rem, 6vw, 3.4rem); font-weight: 800; letter-spacing: -.045em; line-height: 1.05; margin-bottom: 16px; }
.hero-sub { font-size: 1.1rem; color: var(--suave); max-width: 34em; }
.hero-acoes { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 28px; }
.hero-acoes .btn { height: 52px; padding: 0 24px; font-size: 15px; border-radius: 16px; }
.hero-selos { position: relative; display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; align-content: center; min-height: 300px; padding: 32px; border-radius: var(--raio-x); background: var(--sup-card); box-shadow: var(--sombra); overflow: hidden; }
.hero-selos .selo { animation: flutuar 4s ease-in-out infinite; animation-delay: calc(var(--i) * -.5s); }
@keyframes flutuar { 50% { transform: translateY(-6px); } }
.sobre { max-width: 1100px; margin: 0 auto; padding: 28px 24px; font-size: 1.05rem; color: var(--suave); }
.sobre p { max-width: 640px; border-top: 1px solid var(--borda); padding-top: 28px; }
@media (max-width: 760px) { .hero { grid-template-columns: 1fr; gap: 28px; padding: 8px 16px 24px; } .hero-selos { min-height: 0; } .sobre { padding: 16px; } }
.auth { display: flex; justify-content: center; padding: 24px 16px; }
.auth-caixa { width: 100%; max-width: 400px; background: var(--sup-card); border-radius: var(--raio-x); box-shadow: var(--sombra); padding: 40px 32px; }
.auth-caixa h1 { text-align: center; font-size: 1.875rem; margin-bottom: 24px; }
.auth-caixa > p { margin-top: 20px; }
.pagina-auth .auth { min-height: 70vh; align-items: center; }
.lista-check { list-style: none; padding: 0; margin: 0 0 16px; display: grid; gap: 4px; font-size: 14px; }
.lista-check .ok { color: var(--ok); } .lista-check .falha { color: var(--erro); font-weight: 650; }
@media (max-width: 480px) { .auth-caixa { padding: 32px 20px; } }
.texto-legal { line-height: 1.65; }
.texto-legal h1 { margin-bottom: 4px; }
.texto-legal h2 { font-size: 1.25rem; margin: 32px 0 8px; }
.texto-legal ul { margin: 0 0 12px; padding-left: 20px; display: grid; gap: 6px; }
.rodape { text-align: center; color: var(--suave); font-size: 12px; padding: 32px 16px; }
.rodape a { color: inherit; text-decoration: underline; }

/* ---------- Painel admin (usa este arquivo + admin.css) ---------- */
.cards .card { border-radius: var(--raio-g); padding: 18px; }
.cards .card b { font-weight: 700; }
body.adm .aviso { max-width: none; }
body.adm .adm-menu nav a.ativo { background: var(--pri-leve); color: var(--link); font-weight: 700; }
.perfil-topo .avatar-g { width: 110px; height: 110px; }
.perfil-info { flex: 1; min-width: 0; }
body.adm .perfil-topo { display: flex; gap: 28px; align-items: flex-start; padding: 8px 0 24px; }
body.adm .perfil-nome { display: flex; flex-wrap: wrap; align-items: baseline; gap: 12px; }
body.adm .perfil-nome h1 { font-size: 1.4rem; font-weight: 700; }
.tabela .autor img { width: 32px; height: 32px; }
@media (max-width: 600px) { body.adm .perfil-topo { flex-direction: column; align-items: center; text-align: center; } }
