/* Decifra — vidro desfocado no estilo do Absolute Lead. Temas escuros + um claro; intensidade do vidro ajustável. */
:root {
  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "Cascadia Code", "SF Mono", Consolas, monospace;
  --r-sm: 10px; --r-md: 16px; --r-lg: 24px; --r-xl: 32px;
  --ease: cubic-bezier(.22, .8, .24, 1);
  --blur: 22px; --fs: 15px;
  --safe-b: env(safe-area-inset-bottom, 0px); --safe-t: env(safe-area-inset-top, 0px);
}
[data-theme="hud"], :root {
  color-scheme: dark;
  --bg-base: #050a14; --text: #e8f3ff; --text-2: #bcd0e6; --muted: #9fb4cc;
  --glass: rgba(14, 26, 44, .52); --glass-strong: rgba(12, 22, 38, .82); --glass-soft: rgba(80, 150, 200, .08);
  --edge: rgba(120, 215, 255, .2); --edge-soft: rgba(120, 215, 255, .1);
  --shadow: 0 20px 60px rgba(0, 0, 0, .55), 0 0 0 1px rgba(53, 216, 255, .05), inset 0 1px 0 rgba(160, 230, 255, .12);
  --accent: #35d8ff; --accent-2: #ffb347; --accent-ink: #03121a; --accent-soft: rgba(53, 216, 255, .14); --glow: rgba(53, 216, 255, .45);
  --ok: #4be3a8; --warn: #ffc857; --bad: #ff9a92;
  --orb-1: #0e4a6b; --orb-2: #08223f; --orb-3: #0b6e7a; --orb-4: #7a4a12; --grid: rgba(53, 216, 255, .05);
}
[data-theme="violeta"] {
  --bg-base: #0a0716; --text: #f1ecff; --text-2: #cfc4ec; --muted: #ab9fce;
  --glass: rgba(30, 20, 56, .52); --glass-strong: rgba(22, 14, 42, .84); --glass-soft: rgba(160, 130, 255, .09);
  --edge: rgba(180, 150, 255, .22); --edge-soft: rgba(180, 150, 255, .11);
  --shadow: 0 20px 60px rgba(0, 0, 0, .55), inset 0 1px 0 rgba(210, 190, 255, .12);
  --accent: #a78bfa; --accent-2: #f472b6; --accent-ink: #12082b; --accent-soft: rgba(167, 139, 250, .16); --glow: rgba(167, 139, 250, .45);
  --orb-1: #3b1d7a; --orb-2: #150a36; --orb-3: #5b21b6; --orb-4: #7a1d55; --grid: rgba(167, 139, 250, .05);
}
[data-theme="esmeralda"] {
  --bg-base: #04100c; --text: #e9fff6; --text-2: #bfe3d3; --muted: #97c2ae;
  --glass: rgba(12, 38, 30, .52); --glass-strong: rgba(8, 28, 22, .84); --glass-soft: rgba(80, 220, 160, .08);
  --edge: rgba(110, 240, 180, .2); --edge-soft: rgba(110, 240, 180, .1);
  --shadow: 0 20px 60px rgba(0, 0, 0, .55), inset 0 1px 0 rgba(170, 255, 215, .1);
  --accent: #34d399; --accent-2: #fbbf24; --accent-ink: #03170f; --accent-soft: rgba(52, 211, 153, .14); --glow: rgba(52, 211, 153, .42);
  --orb-1: #0b5a41; --orb-2: #052a20; --orb-3: #0f766e; --orb-4: #6b5310; --grid: rgba(52, 211, 153, .05);
}
[data-theme="ambar"] {
  --bg-base: #110a04; --text: #fff5e6; --text-2: #e8d3b4; --muted: #c4a986;
  --glass: rgba(44, 28, 12, .52); --glass-strong: rgba(32, 20, 8, .85); --glass-soft: rgba(255, 180, 80, .08);
  --edge: rgba(255, 200, 120, .2); --edge-soft: rgba(255, 200, 120, .1);
  --shadow: 0 20px 60px rgba(0, 0, 0, .55), inset 0 1px 0 rgba(255, 225, 170, .1);
  --accent: #fbbf24; --accent-2: #fb7185; --accent-ink: #1c1203; --accent-soft: rgba(251, 191, 36, .14); --glow: rgba(251, 191, 36, .4);
  --orb-1: #7a4a12; --orb-2: #2b1705; --orb-3: #92400e; --orb-4: #7a1d2e; --grid: rgba(251, 191, 36, .045);
}
[data-theme="rubi"] {
  --bg-base: #12060a; --text: #fff0f2; --text-2: #ecc8cf; --muted: #c79aa4;
  --glass: rgba(48, 16, 26, .52); --glass-strong: rgba(34, 10, 18, .85); --glass-soft: rgba(255, 110, 140, .08);
  --edge: rgba(255, 150, 170, .2); --edge-soft: rgba(255, 150, 170, .1);
  --shadow: 0 20px 60px rgba(0, 0, 0, .55), inset 0 1px 0 rgba(255, 200, 210, .1);
  --accent: #fb7185; --accent-2: #fbbf24; --accent-ink: #20060c; --accent-soft: rgba(251, 113, 133, .15); --glow: rgba(251, 113, 133, .42);
  --orb-1: #7a1d2e; --orb-2: #2a0810; --orb-3: #9d174d; --orb-4: #7a4a12; --grid: rgba(251, 113, 133, .045);
}
[data-theme="grafite"] {
  --bg-base: #08090b; --text: #f2f3f5; --text-2: #c9ccd2; --muted: #9da2ab;
  --glass: rgba(30, 32, 38, .55); --glass-strong: rgba(20, 22, 26, .88); --glass-soft: rgba(255, 255, 255, .06);
  --edge: rgba(255, 255, 255, .14); --edge-soft: rgba(255, 255, 255, .08);
  --shadow: 0 20px 60px rgba(0, 0, 0, .6), inset 0 1px 0 rgba(255, 255, 255, .08);
  --accent: #f2f3f5; --accent-2: #8ab4ff; --accent-ink: #0b0c0e; --accent-soft: rgba(255, 255, 255, .1); --glow: rgba(255, 255, 255, .25);
  --orb-1: #2a2d35; --orb-2: #121318; --orb-3: #23303f; --orb-4: #2f2a24; --grid: rgba(255, 255, 255, .03);
}
[data-theme="claro"] {
  color-scheme: light;
  --bg-base: #cdb89f; --text: #1c1814; --text-2: #2f2923; --muted: #4f463c;
  --glass: rgba(255, 252, 247, .5); --glass-strong: rgba(255, 252, 247, .8); --glass-soft: rgba(255, 255, 255, .32);
  --edge: rgba(255, 255, 255, .62); --edge-soft: rgba(80, 60, 40, .14);
  --shadow: 0 18px 50px rgba(70, 48, 28, .22), inset 0 1px 0 rgba(255, 255, 255, .6);
  --accent: #095640; --accent-2: #b8651b; --accent-ink: #ffffff; --accent-soft: rgba(9, 86, 64, .14); --glow: rgba(9, 86, 64, .25);
  --ok: #0a5638; --warn: #6b3a02; --bad: #8f1a12;
  --orb-1: #f6e8d4; --orb-2: #8a6a4a; --orb-3: #9fc9bb; --orb-4: #e7a566; --grid: transparent;
}
html[data-vidro="leve"] { --blur: 10px; }
html[data-vidro="forte"] { --blur: 38px; }
html[data-texto="grande"] { --fs: 17px; }

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { height: 100%; margin: 0; }
body { font-family: var(--font); color: var(--text); background: var(--bg-base); font-size: var(--fs); line-height: 1.5; -webkit-font-smoothing: antialiased; overflow-x: hidden; overscroll-behavior-y: none; }
h1, h2, h3, h4 { margin: 0; line-height: 1.2; letter-spacing: -.01em; }
p { margin: 0; }
a { color: var(--accent); text-underline-offset: 3px; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
[hidden] { display: none !important; }

.scene { position: fixed; inset: 0; z-index: -1; overflow: hidden; background: var(--bg-base); }
.scene .orb { position: absolute; border-radius: 50%; opacity: .85; animation: drift 28s var(--ease) infinite alternate;
  background: radial-gradient(closest-side, var(--c) 0, var(--c) 52%, color-mix(in srgb, var(--c) 45%, transparent) 78%, transparent 100%); }
.scene .o1 { --c: var(--orb-1); width: 90vmax; height: 90vmax; left: -34vmax; top: -40vmax; }
.scene .o2 { --c: var(--orb-2); width: 70vmax; height: 80vmax; right: -30vmax; top: 4vh; animation-duration: 34s; }
.scene .o3 { --c: var(--orb-3); width: 64vmax; height: 64vmax; left: 6vw; bottom: -38vmax; animation-duration: 40s; }
.scene .o4 { --c: var(--orb-4); width: 46vmax; height: 46vmax; right: -8vw; bottom: -10vmax; opacity: .55; animation-duration: 31s; }
.scene::after { content: ""; position: absolute; inset: 0; opacity: .6; background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px); background-size: 56px 56px; mask-image: radial-gradient(circle at 50% 35%, #000 0, transparent 75%); -webkit-mask-image: radial-gradient(circle at 50% 35%, #000 0, transparent 75%); }
@keyframes drift { from { transform: translate3d(0, 0, 0) scale(1); } to { transform: translate3d(4vw, 3vh, 0) scale(1.08); } }
html[data-fundo="parado"] .scene .orb { animation: none; }

.glass { background: var(--glass); backdrop-filter: blur(var(--blur)) saturate(150%); -webkit-backdrop-filter: blur(var(--blur)) saturate(150%); border: 1px solid var(--edge); box-shadow: var(--shadow); border-radius: var(--r-lg); }
.glass-strong { background: var(--glass-strong); backdrop-filter: blur(var(--blur)) saturate(150%); -webkit-backdrop-filter: blur(var(--blur)) saturate(150%); border: 1px solid var(--edge); border-radius: var(--r-md); }
.card { padding: 16px; border-radius: var(--r-md); background: var(--glass-soft); border: 1px solid var(--edge-soft); min-width: 0; }
.card.lift { background: var(--glass-strong); }
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) { .glass, .glass-strong { background: var(--glass-strong); } }
@media (prefers-reduced-motion: reduce) { .scene .orb { animation: none; } * { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; } }

/* Estrutura */
#app { max-width: 1040px; margin: 0 auto; padding: calc(12px + var(--safe-t)) 12px calc(104px + var(--safe-b)); min-height: 100%; }
.topbar { position: sticky; top: calc(8px + var(--safe-t)); z-index: 20; display: flex; align-items: center; gap: 10px; padding: 8px 10px 8px 14px; border-radius: 999px; margin-bottom: 14px; }
.topbar h1 { font-size: 18px; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; }
.brand-mark { flex: none; width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; background: linear-gradient(140deg, var(--accent), var(--accent-2)); color: var(--accent-ink); box-shadow: 0 0 18px var(--glow); }
.brand-mark svg { width: 20px; height: 20px; }
.brand b { font-size: 18px; letter-spacing: -.02em; }
.tabbar { position: fixed; left: 50%; bottom: calc(14px + var(--safe-b)); transform: translateX(-50%); z-index: 30; display: flex; gap: 2px; padding: 6px; border-radius: 999px; max-width: calc(100vw - 20px); }
.tabbar a { display: flex; flex-direction: column; align-items: center; gap: 2px; min-width: 70px; padding: 7px 12px; border-radius: 999px; color: var(--text-2); text-decoration: none; font-size: 11px; font-weight: 600; white-space: nowrap; position: relative; }
.tabbar a svg { width: 21px; height: 21px; }
.tabbar a[aria-current="page"] { background: var(--accent); color: var(--accent-ink); box-shadow: 0 0 22px var(--glow); }
@media (max-width: 480px) {
  .tabbar { width: calc(100vw - 20px); }
  .tabbar a { flex: 1; min-width: 0; padding: 7px 2px; font-size: 10.5px; }
  .tabbar .ponto { right: auto; left: calc(50% + 7px); }
}
.tabbar .ponto { position: absolute; top: 5px; right: 16px; width: 8px; height: 8px; border-radius: 50%; background: var(--accent-2); }
.view { animation: entra .28s var(--ease); }
@keyframes entra { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* Controles */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px; padding: 0 18px; border-radius: 999px; border: 1px solid var(--edge-soft); background: var(--glass-soft); color: var(--text); font-weight: 600; font-size: 14px; cursor: pointer; transition: transform .15s var(--ease), box-shadow .2s, background .2s; white-space: nowrap; text-decoration: none; }
.btn:active { transform: scale(.97); }
.btn.primary { background: var(--accent); color: var(--accent-ink); border-color: transparent; box-shadow: 0 0 20px color-mix(in srgb, var(--glow) 60%, transparent); }
.btn.danger { color: var(--bad); }
.btn.sm { min-height: 34px; padding: 0 13px; font-size: 13px; }
.btn.icon { width: 42px; padding: 0; flex: none; }
.btn.sm.icon { width: 34px; }
.btn.block { width: 100%; }
.btn[disabled] { opacity: .5; pointer-events: none; }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn.on { background: var(--accent-soft); border-color: var(--accent); color: var(--accent); }
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.field > label, .label { font-size: 13px; font-weight: 600; color: var(--text-2); }
.hint { font-size: 12.5px; color: var(--muted); }
.input, .select, .textarea { width: 100%; min-height: 44px; padding: 10px 14px; border-radius: 14px; border: 1px solid var(--edge-soft); background: var(--glass-strong); color: var(--text); font: inherit; }
.textarea { resize: vertical; min-height: 84px; }
.input::placeholder, .textarea::placeholder { color: var(--muted); }
.input:focus, .select:focus, .textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.search { position: relative; flex: 1; min-width: 0; }
.search svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--muted); }
.search .input { padding-left: 42px; border-radius: 999px; }
.chips { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding: 2px 0; }
.chips::-webkit-scrollbar { display: none; }
.chip { display: inline-flex; align-items: center; gap: 5px; padding: 3px 11px; border-radius: 999px; font-size: 12px; font-weight: 700; background: var(--glass-soft); border: 1px solid var(--edge-soft); color: var(--text-2); white-space: nowrap; }
.chip svg { width: 13px; height: 13px; }
button.chip { cursor: pointer; padding: 7px 14px; font-size: 13px; }
button.chip.on { background: var(--accent); color: var(--accent-ink); border-color: transparent; }
.chip.ok { color: var(--ok); } .chip.warn { color: var(--warn); } .chip.bad { color: var(--bad); }
.chip.accent { color: var(--accent); background: var(--accent-soft); border-color: transparent; }
.row { display: flex; align-items: center; gap: 10px; } .row.wrap { flex-wrap: wrap; } .row.between { justify-content: space-between; } .col { display: flex; flex-direction: column; gap: 10px; }
.grow { flex: 1; min-width: 0; } .mt { margin-top: 14px; } .mt-l { margin-top: 24px; } .muted { color: var(--muted); } .small { font-size: 13px; } .tiny { font-size: 12px; } .bold { font-weight: 700; } .mono { font-family: var(--mono); } .num { font-variant-numeric: tabular-nums; } .center { text-align: center; }
.sec { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 700; margin: 22px 4px 10px; }
.switch { position: relative; width: 48px; height: 28px; flex: none; }
.switch input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; z-index: 1; }
.switch i { position: absolute; inset: 0; border-radius: 999px; background: var(--edge-soft); border: 1px solid var(--edge-soft); transition: background .2s; }
.switch i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: var(--text-2); transition: transform .2s var(--ease), background .2s; }
.switch input:checked + i { background: var(--accent); }
.switch input:checked + i::after { transform: translateX(20px); background: var(--accent-ink); }
.linha { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--edge-soft); }
.linha:last-child { border-bottom: 0; }
.seg { display: flex; gap: 4px; padding: 4px; border-radius: 999px; background: var(--glass-soft); border: 1px solid var(--edge-soft); overflow-x: auto; scrollbar-width: none; }
.seg::-webkit-scrollbar { display: none; }
.seg button { flex: 1; min-height: 36px; padding: 0 11px; border-radius: 999px; border: 0; background: none; cursor: pointer; font-weight: 600; font-size: 13.5px; color: var(--text-2); white-space: nowrap; }
.seg button[aria-selected="true"], .seg button[aria-pressed="true"] { background: var(--accent); color: var(--accent-ink); box-shadow: 0 0 16px color-mix(in srgb, var(--glow) 60%, transparent); }
.empty { text-align: center; padding: 44px 18px; color: var(--muted); }
.empty svg { width: 44px; height: 44px; opacity: .7; margin-bottom: 10px; color: var(--accent); }
.empty b { display: block; color: var(--text); font-size: 17px; margin-bottom: 6px; }
.passos { text-align: left; max-width: 380px; margin: 16px auto 0; display: flex; flex-direction: column; gap: 10px; }
.passos div { display: flex; gap: 12px; align-items: flex-start; }
.passos i { flex: none; width: 26px; height: 26px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-style: normal; font-weight: 800; font-size: 13px; }

/* Biblioteca */
.grade { display: grid; grid-template-columns: repeat(var(--cols, 2), minmax(0, 1fr)); gap: 12px; }
@media (min-width: 700px) { .grade { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.post { position: relative; border-radius: var(--r-md); overflow: hidden; background: var(--glass-strong); border: 1px solid var(--edge-soft); cursor: pointer; text-align: left; padding: 0; display: block; width: 100%; transition: transform .2s var(--ease), box-shadow .2s; }
.post:active { transform: scale(.98); }
.post.novo { box-shadow: 0 0 0 2px var(--accent), 0 0 28px var(--glow); }
.post .capa { position: relative; aspect-ratio: 9 / 13; background: linear-gradient(160deg, var(--orb-1), var(--orb-2)); display: grid; place-items: center; }
.post .capa img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.post .capa > svg { width: 34px; height: 34px; opacity: .5; }
.post .capa::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,.35) 0, transparent 26%, transparent 55%, rgba(0,0,0,.72) 100%); pointer-events: none; }
.post .sobre { position: absolute; z-index: 2; left: 8px; right: 8px; display: flex; justify-content: space-between; align-items: center; gap: 6px; color: #fff; }
.post .sobre.t { top: 8px; } .post .sobre.b { bottom: 8px; font-size: 12px; font-weight: 700; text-shadow: 0 1px 4px rgba(0,0,0,.7); }
.selo { display: inline-flex; align-items: center; gap: 4px; padding: 3px 8px; border-radius: 999px; background: rgba(0,0,0,.5); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); font-size: 11px; font-weight: 700; color: #fff; }
.selo svg { width: 13px; height: 13px; }
.selo.nota { background: var(--accent); color: var(--accent-ink); font-size: 13px; padding: 3px 9px; }
.post .txt { padding: 10px 12px 12px; }
.post .txt b { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-size: 13.5px; line-height: 1.3; }
.post .txt span { display: block; font-size: 12px; color: var(--muted); margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fase { position: absolute; inset: 0; z-index: 3; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; background: rgba(0,0,0,.72); color: #fff; font-size: 12.5px; font-weight: 700; text-align: center; padding: 10px; }
.giro { width: 28px; height: 28px; border-radius: 50%; border: 3px solid rgba(255,255,255,.25); border-top-color: var(--accent); animation: gira 1s linear infinite; }
@keyframes gira { to { transform: rotate(360deg); } }
.fab { position: fixed; right: max(16px, calc(50% - 504px)); bottom: calc(92px + var(--safe-b)); z-index: 25; width: 56px; height: 56px; border-radius: 50%; border: 0; background: linear-gradient(140deg, var(--accent), var(--accent-2)); color: var(--accent-ink); display: grid; place-items: center; cursor: pointer; box-shadow: 0 8px 28px var(--glow); }
.fab svg { width: 26px; height: 26px; }

/* Post aberto */
.palco { position: relative; border-radius: var(--r-lg); overflow: hidden; background: #000; display: grid; place-items: center; max-height: 62vh; }
.palco.mini, .palco.mini video, .palco.mini img { max-height: 26vh; }
.palco video, .palco img { display: block; width: 100%; max-height: 62vh; object-fit: contain; background: #000; }
.cab-post { display: flex; gap: 12px; align-items: center; margin: 14px 2px; }
.anel { position: relative; width: 74px; height: 74px; flex: none; display: grid; place-items: center; }
.anel svg { position: absolute; inset: 0; transform: rotate(-90deg); }
.anel b { font-size: 24px; font-variant-numeric: tabular-nums; }
.barras { display: grid; grid-template-columns: auto 1fr auto; gap: 8px 10px; align-items: center; font-size: 13px; }
.progress { height: 7px; border-radius: 999px; background: var(--edge-soft); overflow: hidden; }
.progress > i { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--accent), var(--accent-2)); }
.fator { border-left: 3px solid var(--accent); padding-left: 12px; margin: 14px 0; }
.fator.medio { border-color: var(--accent-2); } .fator.baixo { border-color: var(--edge); }
.fator h4 { font-size: 15px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.fator p { font-size: 14px; color: var(--text-2); margin-top: 4px; }
.fator p.mec { color: var(--muted); font-size: 13px; }
.lista { margin: 8px 0 0; padding-left: 20px; display: flex; flex-direction: column; gap: 6px; font-size: 14px; color: var(--text-2); }
.trilho { display: flex; height: 34px; border-radius: 10px; overflow: hidden; border: 1px solid var(--edge-soft); margin: 10px 0 4px; }
.trilho button { border: 0; padding: 0; cursor: pointer; min-width: 3px; border-right: 1px solid rgba(0,0,0,.35); opacity: .9; }
.cena { display: grid; grid-template-columns: 62px 1fr; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--edge-soft); }
.cena:last-child { border-bottom: 0; }
.tempo { font-family: var(--mono); font-size: 12px; color: var(--accent); background: var(--accent-soft); border: 0; border-radius: 8px; padding: 4px 6px; cursor: pointer; align-self: start; font-weight: 700; }
.cena dl { margin: 6px 0 0; display: grid; grid-template-columns: auto 1fr; gap: 3px 8px; font-size: 13px; }
.cena dt { color: var(--muted); } .cena dd { margin: 0; color: var(--text-2); }
.fala-l { display: flex; gap: 10px; padding: 7px 0; font-size: 14.5px; align-items: flex-start; }
.grafico { width: 100%; height: auto; display: block; overflow: visible; touch-action: none; }
.grafico text { fill: var(--muted); font-size: 10px; font-family: var(--font); }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(88px, 1fr)); gap: 8px; }
.kpi { padding: 10px 12px; border-radius: 14px; background: var(--glass-soft); border: 1px solid var(--edge-soft); }
.kpi span { display: block; font-size: 11.5px; color: var(--muted); font-weight: 600; }
.kpi b { font-size: 17px; font-variant-numeric: tabular-nums; }
.passo-f { display: grid; grid-template-columns: 30px 1fr; gap: 12px; padding: 10px 0; }
.passo-f i { width: 30px; height: 30px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-style: normal; font-weight: 800; font-size: 13px; }

/* Chat */
.chat { display: flex; flex-direction: column; gap: 10px; }
.msg { max-width: 88%; padding: 10px 14px; border-radius: 18px; font-size: 14.5px; word-wrap: break-word; overflow-wrap: anywhere; }
.msg.user { align-self: flex-end; background: var(--accent); color: var(--accent-ink); border-bottom-right-radius: 6px; }
.msg.model { align-self: flex-start; background: var(--glass-strong); border: 1px solid var(--edge-soft); border-bottom-left-radius: 6px; }
.msg p + p, .msg ul, .msg ol { margin-top: 8px; } .msg ul, .msg ol { padding-left: 20px; margin-bottom: 0; } .msg li + li { margin-top: 4px; }
.msg h3, .msg h4 { font-size: 15px; margin: 10px 0 4px; } .msg code { font-family: var(--mono); font-size: 13px; background: var(--glass-soft); padding: 1px 5px; border-radius: 5px; }
.msg .meta { display: block; font-size: 11px; opacity: .65; margin-top: 6px; }
.digitando::after { content: "▍"; animation: pisca 1s steps(2) infinite; color: var(--accent); }
@keyframes pisca { 50% { opacity: 0; } }
.compor { position: sticky; bottom: calc(86px + var(--safe-b)); z-index: 10; display: flex; gap: 8px; align-items: flex-end; padding: 8px; border-radius: 26px; margin-top: 14px; }
.compor textarea { flex: 1; min-height: 42px; max-height: 140px; resize: none; border: 0; background: none; color: var(--text); font: inherit; padding: 10px 8px; outline: none; }

/* Folhas e avisos */
.veu { position: fixed; inset: 0; z-index: 50; background: rgba(0,0,0,.5); display: flex; align-items: flex-end; justify-content: center; animation: some .2s; }
@keyframes some { from { opacity: 0; } }
.folha { width: 100%; max-width: 560px; max-height: 88vh; overflow-y: auto; padding: 20px 18px calc(22px + var(--safe-b)); border-radius: 28px 28px 0 0; animation: sobe .3s var(--ease); }
@keyframes sobe { from { transform: translateY(40px); opacity: 0; } }
@media (min-width: 700px) { .veu { align-items: center; } .folha { border-radius: 28px; } }
.folha h2 { font-size: 20px; margin-bottom: 14px; }
.toasts { position: fixed; left: 50%; top: calc(14px + var(--safe-t)); transform: translateX(-50%); z-index: 60; display: flex; flex-direction: column; gap: 8px; width: min(92vw, 420px); pointer-events: none; }
.toast { padding: 12px 16px; border-radius: 16px; font-size: 14px; font-weight: 600; animation: sobe .3s var(--ease); pointer-events: auto; display: flex; gap: 10px; align-items: center; justify-content: space-between; }
.toast.bad { border-color: var(--bad); color: var(--bad); }
.temas { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; }
.tema { border: 2px solid transparent; border-radius: 16px; padding: 0; cursor: pointer; overflow: hidden; background: var(--glass-soft); text-align: left; }
.tema[aria-pressed="true"] { border-color: var(--accent); box-shadow: 0 0 18px var(--glow); }
.tema .am { height: 54px; position: relative; }
.tema .am::after { content: ""; position: absolute; left: 10px; right: 10px; bottom: 9px; height: 18px; border-radius: 9px; background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.22); backdrop-filter: blur(6px); }
.tema span { display: block; padding: 6px 10px 8px; font-size: 12.5px; font-weight: 700; }
.job { display: grid; grid-template-columns: 64px 1fr; gap: 12px; align-items: start; }
.job .mini { width: 64px; aspect-ratio: 9 / 13; border-radius: 12px; object-fit: cover; background: var(--glass-soft); }
.logl { font-family: var(--mono); font-size: 11.5px; color: var(--muted); white-space: pre-wrap; margin-top: 6px; }
.opcao { display: flex; gap: 12px; align-items: flex-start; padding: 12px; border-radius: 14px; border: 1px solid var(--edge-soft); background: var(--glass-soft); cursor: pointer; text-align: left; width: 100%; }
.opcao[aria-pressed="true"] { border-color: var(--accent); background: var(--accent-soft); }
.opcao b { display: block; } .opcao span { font-size: 13px; color: var(--muted); }

.chip.bad { border-color: var(--bad); }
button.chip.warn, button.chip.bad { cursor: pointer; }
form.card .field:last-of-type { margin-bottom: 18px; }

.sino { position: relative; }
.sino.tem::after { content: attr(data-n); position: absolute; top: -4px; right: -4px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: var(--accent-2); color: #1a1006; font-size: 11px; font-weight: 800; display: grid; place-items: center; }

/* Vitrine, esperas e originais */
.fase svg { width: 28px; height: 28px; }
.fase.espera svg { color: var(--warn); }
.post .sobre svg { width: 15px; height: 15px; }
.ic-grande svg { width: 34px; height: 34px; color: var(--warn); display: block; margin: 4px auto 10px; }
.ic-pequeno svg { width: 20px; height: 20px; color: var(--warn); display: block; }
.post.vit { cursor: default; }
.vit-abrir { display: block; width: 100%; padding: 0; border: 0; background: none; color: inherit; text-align: left; cursor: pointer; }
.vit-abrir:active { transform: scale(.985); }
.post .txt .vered { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; color: var(--text-2); }
.post .txt .vmeta { white-space: normal; }
.vit-acao { padding: 0 10px 10px; }

/* Tutorial de primeiro uso (prefixo tut-) */
.tut-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.tut [tabindex="-1"]:focus { outline: none; }
.tut-sol { background-image: linear-gradient(var(--glass-strong), var(--glass-strong)); background-color: var(--bg-base); }
.tut section { animation: entra .3s var(--ease); }
.tut section.tut-vez { animation: none; }
.tut-coach { position: relative; margin-top: 14px; padding: 14px 16px; border-radius: 18px; border: 1px solid var(--accent); box-shadow: 0 0 24px color-mix(in srgb, var(--glow) 50%, transparent); animation: tut-flutua 1.5s ease-in-out infinite alternate; }
.tut-coach::after { content: ""; position: absolute; bottom: -8px; left: calc(25% - 7px); width: 14px; height: 14px; transform: rotate(45deg); background: inherit; border: 1px solid var(--accent); border-top: 0; border-left: 0; }
.tut-coach h2 { font-size: 17px; }
.tut-coach p { margin-top: 4px; font-size: 14px; color: var(--text-2); }
@keyframes tut-flutua { to { transform: translateY(-4px); } }
@keyframes tut-pulsa { 0% { box-shadow: 0 0 0 2px var(--accent), 0 0 0 0 var(--glow); } 100% { box-shadow: 0 0 0 2px var(--accent), 0 0 0 14px transparent; } }
.post.tut-alvo { box-shadow: 0 0 0 2px var(--accent), 0 0 28px var(--glow); animation: tut-pulsa 1.8s ease-out infinite; }
.post.tut-vazio { border-style: dashed; cursor: default; display: grid; place-items: center; text-align: center; padding: 16px; color: var(--muted); font-size: 13px; background: transparent; gap: 8px; align-content: center; }
.post.tut-vazio svg { width: 28px; height: 28px; color: var(--accent); opacity: .7; }
.selo.tut-ex { background: var(--accent-2); color: #1a1006; }
.tut-palco { height: 132px; border-radius: var(--r-lg); overflow: hidden; display: grid; place-items: center; position: relative; background: linear-gradient(160deg, #0b6e7a, #08223f); }
.tut-palco svg { width: 40px; height: 40px; color: #fff; opacity: .75; }
.tut-palco span { position: absolute; left: 12px; bottom: 10px; font-size: 12px; font-weight: 700; color: #fff; background: rgba(0,0,0,.5); padding: 2px 9px; border-radius: 99px; }
.tut .tempo.tut-tempo { display: inline-block; cursor: default; margin-bottom: 6px; }
.tut-foco { outline: 2px solid var(--accent); outline-offset: 4px; border-radius: var(--r-md); transition: outline-color .3s; }
.tut-dica { display: flex; gap: 10px; align-items: flex-start; margin-top: 10px; padding: 12px 14px; border-radius: 14px; background: linear-gradient(var(--accent-soft), var(--accent-soft)), var(--glass-strong); border: 1px solid var(--accent); font-size: 14px; line-height: 1.45; color: var(--text); animation: entra .35s var(--ease); }
.tut-dica > svg { flex: none; width: 20px; height: 20px; color: var(--accent-2); margin-top: 1px; }
.tut-dica b { display: block; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); margin-bottom: 2px; }
.tut-dicabar { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(92px + var(--safe-b)); z-index: 35; width: min(406px, calc(100vw - 24px)); padding: 10px 10px 10px 16px; display: flex; align-items: center; gap: 10px; border-radius: 999px; }
.tut-n { flex: 1; min-width: 0; font-size: 13px; font-weight: 700; color: var(--text-2); }
.tut-pips { display: flex; gap: 5px; margin-top: 5px; }
.tut-pips i { width: 6px; height: 6px; border-radius: 99px; background: var(--edge); transition: width .3s var(--ease), background .3s; }
.tut-pips i.on { width: 18px; background: var(--accent); }
.tut section:not(.tut-vez) { padding-bottom: 150px; }
.tut-vez { max-width: 430px; margin: 0 auto; min-height: calc(100dvh - 24px - var(--safe-t) - var(--safe-b)); display: flex; flex-direction: column; }
#app.tut-cheio { padding-bottom: calc(16px + var(--safe-b)); }
.tut-vez h1 { font-size: 28px; letter-spacing: -.025em; margin-top: 14px; }
.tut-lead { margin-top: 8px; font-size: 16px; color: var(--text-2); }
.tut-so { width: max-content; max-width: 100%; margin: 16px 0 4px; }
.tut-vez .passos { margin: 14px 0 0; max-width: none; color: var(--text-2); }
.tut-vez .passos b { color: var(--text); }
.tut-inl { display: inline-flex; vertical-align: -4px; color: var(--accent); }
.tut-inl svg { width: 18px; height: 18px; }
.tut-det { margin-top: 12px; border-radius: 14px; background: var(--glass-soft); border: 1px solid var(--edge-soft); padding: 0 14px; }
.tut-det summary { cursor: pointer; min-height: 46px; display: flex; align-items: center; font-weight: 600; font-size: 14px; list-style: none; gap: 8px; }
.tut-det summary::-webkit-details-marker { display: none; }
.tut-det summary::after { content: "+"; margin-left: auto; font-size: 20px; color: var(--accent); }
.tut-det[open] summary::after { content: "\2212"; }
.tut-det p { font-size: 14px; color: var(--text-2); padding: 0 0 14px; }
.tut-plano { margin-top: 16px; }
.tut-vez .hint { color: var(--text-2); }
.tut-alt { margin-top: 16px; }
.tut-rodape { margin-top: auto; padding-top: 18px; display: flex; flex-direction: column; gap: 8px; }
.tut-rodape .btn { min-height: 50px; font-size: 16px; }
.btn.ghost { background: none; border-color: transparent; color: var(--text-2); }
@media (prefers-reduced-motion: reduce) { .tut-coach, .post.tut-alvo { animation: none; } }

/* ---------- visão rápida (popup do Compartilhar) ---------- */
.rapido { min-height: 100dvh; display: flex; flex-direction: column; justify-content: flex-end; padding: 12px 12px calc(12px + env(safe-area-inset-bottom)); }
.rap-folha { border-radius: 26px; padding: 16px; max-height: 92dvh; overflow-y: auto; animation: rap-sobe .28s cubic-bezier(.2,.8,.2,1); }
@keyframes rap-sobe { from { transform: translateY(40px); opacity: 0; } to { transform: none; opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .rap-folha { animation: none; } }
.rap-cab { display: flex; align-items: center; gap: 12px; }
.rap-cab .grow { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.rap-cab b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rap-capa { width: 52px; height: 68px; flex: none; border-radius: 12px; overflow: hidden; background: var(--glass-2, rgba(255,255,255,.06)); display: grid; place-items: center; }
.rap-capa img { width: 100%; height: 100%; object-fit: cover; }
.rap-nota { display: flex; align-items: center; gap: 14px; }
.rap-nota p { font-weight: 650; font-size: 16px; line-height: 1.35; }
.rap-acoes { display: grid; gap: 10px; }
.rapido .fator { padding: 8px 0; border-top: 1px solid var(--line, rgba(255,255,255,.08)); }
.rapido .fator:first-of-type { border-top: 0; }
/* dentro do app Android a página é transparente: o post de origem continua visível atrás da folha */
body.em-popup, body.em-popup #app { background: transparent !important; }
body.em-popup::before, body.em-popup::after { display: none !important; }
body.em-popup .rapido { background: rgba(0, 0, 0, .35); }
html:has(body.em-popup) { background: transparent !important; }
.rapido .fator { padding-left: 12px; }
.rapido .fator p { font-size: 13.5px; }
/* ações sempre visíveis no rodapé da folha, mesmo com análise longa */
.rap-acoes { position: sticky; bottom: -16px; margin: 12px -16px -16px; padding: 14px 16px 16px; background: linear-gradient(to bottom, transparent, var(--bg-base) 38%); border-radius: 0 0 26px 26px; }
/* topo: o nome nunca fica embaixo dos selos */
.topbar > .chip, .topbar > button.chip { flex: none; white-space: nowrap; }
.brand b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.topo-fila { gap: 6px; }
@media (max-width: 460px) { .so-largo { display: none; } }
.aviso-app { display: flex; gap: 12px; align-items: center; }
