:root {
  --bg: #FAF9F5;
  --sidebar: #F4F2EC;
  --surface: #FFFFFF;
  --text: #2B2A27;
  --text-strong: #1A1917;
  --muted: #7A776F;
  --border: #E6E2D8;
  --border-strong: #D6D1C4;
  --hover: #ECE9E0;
  --user-bubble: #EFECE3;
  --accent: #D2693F;
  --accent-hover: #BC5A33;
  --accent-soft: #F6E3D9;
  --code-bg: #F2EFE7;
  --focus: #C9C2B2;
  --shadow: 0 1px 2px rgba(40, 30, 10, .04), 0 6px 24px rgba(40, 30, 10, .06);
  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --sans: Inter, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --sidebar-w: 268px;
  --col: 760px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #262624; --sidebar: #1F1E1C; --surface: #30302D; --text: #E8E6DF; --text-strong: #F7F5EF;
    --muted: #A19E95; --border: #3A3936; --border-strong: #4A4844; --hover: #33322F; --user-bubble: #141412;
    --accent: #DC7A50; --accent-hover: #E68C64; --accent-soft: #4A3328; --code-bg: #1E1D1B; --focus: #5A5752;
    --shadow: 0 1px 2px rgba(0,0,0,.2), 0 6px 24px rgba(0,0,0,.25);
  }
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { height: 100%; margin: 0; touch-action: pan-x pan-y; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { background: var(--bg); color: var(--text); font-family: var(--sans); font-size: 15px; -webkit-font-smoothing: antialiased; }
button { font: inherit; color: inherit; cursor: pointer; }
svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

.app { display: flex; height: 100dvh; overflow: hidden; }

/* ---------- Sidebar ---------- */
.sidebar { width: var(--sidebar-w); flex-shrink: 0; background: var(--sidebar); border-right: 1px solid var(--border); display: flex; flex-direction: column; padding: 14px 10px; }
.sidebar-top { display: flex; align-items: center; justify-content: space-between; padding: 2px 8px 14px; }
.brand { display: flex; align-items: center; text-decoration: none; }
.brand img { height: 40px; width: auto; display: block; }
.brand .logo-dark { display: none; }
@media (prefers-color-scheme: dark) { .brand .logo-light { display: none; } .brand .logo-dark { display: block; } }
.new-chat { display: flex; align-items: center; gap: 10px; border: 0; background: transparent; padding: 9px 10px; border-radius: 10px; font-weight: 500; color: var(--text-strong); text-align: left; }
.new-chat svg { width: 22px; height: 22px; padding: 3px; border-radius: 50%; background: var(--accent); color: #fff; stroke-width: 2.4; }
.new-chat:hover { background: var(--hover); }
.side-label { font-size: 12px; color: var(--muted); padding: 18px 10px 6px; font-weight: 500; }
.history { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 1px; }
.history-item { display: flex; align-items: center; border-radius: 8px; }
.history-item a { flex: 1; min-width: 0; padding: 7px 10px; color: var(--text); text-decoration: none; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.history-item:hover, .history-item.active { background: var(--hover); }
.history-item .del { opacity: 0; border: 0; background: none; padding: 6px; margin-right: 2px; color: var(--muted); border-radius: 6px; }
.history-item:hover .del { opacity: 1; }
.history-item .del:hover { color: var(--text-strong); background: var(--border); }
.history-item .del svg { width: 15px; height: 15px; }
.sidebar-foot { display: flex; align-items: center; gap: 10px; padding: 12px 8px 4px; border-top: 1px solid var(--border); margin-top: 8px; }
.avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--text-strong); color: var(--bg); display: grid; place-items: center; font-weight: 600; font-size: 14px; }
.foot-text { display: flex; flex-direction: column; font-size: 13px; line-height: 1.3; }
.foot-text span { color: var(--muted); font-size: 12px; }

/* ---------- Main ---------- */
.main { flex: 1; display: flex; flex-direction: column; min-width: 0; position: relative; }
.topbar { height: 52px; display: flex; align-items: center; gap: 8px; padding: 0 16px; flex-shrink: 0; }
.chat-title { flex: 1; text-align: center; font-size: 14px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.icon-btn { border: 0; background: transparent; width: 36px; height: 36px; border-radius: 8px; display: grid; place-items: center; color: var(--muted); }
.icon-btn:hover { background: var(--hover); color: var(--text-strong); }
.only-mobile { display: none; }

.thread { flex: 1; overflow-y: auto; scroll-behavior: smooth; }
.messages { max-width: var(--col); margin: 0 auto; padding: 8px 24px 40px; }

/* Welcome (estado inicial: composer centralizado) */
.welcome { display: none; }
.app.empty .welcome { display: flex; justify-content: center; }
.app.empty .thread { flex: 0 0 auto; margin-top: 22vh; overflow: visible; }
.app.empty .composer-wrap { padding-top: 26px; }
.app.empty .disclaimer { display: none; }
.app:not(.empty) .suggestions { display: none; }
.welcome { padding: 0 24px; }
.greeting { display: flex; align-items: center; justify-content: center; gap: 16px; max-width: var(--col); font-family: var(--serif); font-weight: 400; font-size: clamp(28px, 4.2vw, 40px); line-height: 1.2; letter-spacing: -.02em; color: var(--text-strong); margin: 0; text-align: center; text-wrap: balance; }
.greet-dot { flex: 0 0 auto; width: .62em; height: .62em; border-radius: 50%; background: var(--accent); animation: dot-in .7s cubic-bezier(.2,.9,.3,1.3) both; }
#greetingText { animation: fade-up .6s ease .1s both; }
@keyframes dot-in { from { transform: scale(0); } to { transform: scale(1); } }
@keyframes fade-up { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* Mensagens */
.msg { margin: 26px 0; }
.msg.user { display: flex; justify-content: flex-end; }
.msg.user .bubble { background: var(--user-bubble); padding: 10px 16px; border-radius: 18px; max-width: 85%; white-space: pre-wrap; word-wrap: break-word; line-height: 1.55; }

.msg.assistant .body { font-family: var(--serif); font-size: 17px; line-height: 1.68; color: var(--text-strong); }
.body > :first-child { margin-top: 0; }
.body p { margin: 0 0 14px; }
.body h1, .body h2, .body h3 { font-family: var(--serif); font-weight: 600; line-height: 1.3; margin: 22px 0 10px; }
.body h1 { font-size: 23px; } .body h2 { font-size: 20px; } .body h3 { font-size: 18px; }
.body ul, .body ol { padding-left: 24px; margin: 0 0 14px; }
.body li { margin: 5px 0; }
.body li::marker { color: var(--muted); }
.body a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; text-decoration-thickness: 1px; }
.body strong { font-weight: 600; }
.body blockquote { margin: 0 0 14px; padding-left: 14px; border-left: 3px solid var(--border-strong); color: var(--muted); }
.body code { font-family: var(--mono); font-size: .84em; background: var(--code-bg); border: 1px solid var(--border); padding: 1px 5px; border-radius: 5px; }
.body pre { background: var(--code-bg); border: 1px solid var(--border); border-radius: 10px; padding: 14px 16px; overflow-x: auto; font-size: 13.5px; line-height: 1.5; }
.body pre code { background: none; border: 0; padding: 0; }
.body table { border-collapse: collapse; width: 100%; margin: 4px 0 16px; font-family: var(--sans); font-size: 14px; display: block; overflow-x: auto; }
.body th, .body td { border-bottom: 1px solid var(--border); padding: 8px 12px; text-align: left; }
.body th { font-weight: 600; border-bottom: 1px solid var(--border-strong); }
.body hr { border: 0; border-top: 1px solid var(--border); margin: 20px 0; }

/* Citações [n] */
.cite { display: inline-flex; align-items: center; justify-content: center; min-width: 18px; height: 18px; padding: 0 5px; margin: 0 1px; border-radius: 6px; background: var(--hover); color: var(--muted) !important; font-family: var(--sans); font-size: 11px; font-weight: 600; text-decoration: none !important; vertical-align: 2px; transition: background .15s, color .15s; }
.cite:hover { background: var(--accent); color: #fff !important; }

/* Status / pesquisa */
.status { display: flex; align-items: center; gap: 10px; font-family: var(--sans); font-size: 14px; color: var(--muted); margin-bottom: 14px; }
.status .spark { width: 18px; height: 18px; animation: spin 1.6s linear infinite; color: var(--accent); }
.status .queries { display: flex; flex-wrap: wrap; gap: 6px; }
.status .q { background: var(--surface); border: 1px solid var(--border); padding: 2px 9px; border-radius: 999px; font-size: 12.5px; }
.status.done .spark { animation: none; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Fontes */
.sources { display: flex; gap: 8px; overflow-x: auto; margin: 0 0 18px; padding-bottom: 4px; scrollbar-width: thin; }
.source { flex: 0 0 196px; display: flex; flex-direction: column; gap: 6px; padding: 10px 12px; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; text-decoration: none; color: var(--text); font-family: var(--sans); transition: border-color .15s, transform .15s; }
.source:hover { border-color: var(--border-strong); transform: translateY(-1px); }
.source .t { font-size: 13px; line-height: 1.35; font-weight: 500; color: var(--text-strong); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.source .h { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.source .h img { width: 14px; height: 14px; border-radius: 3px; }
.source .n { margin-left: auto; font-weight: 600; }
.source.flash { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }

/* Resultados da web (10 links) */
.links { margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--border); font-family: var(--sans); }
.links-head { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--muted); margin-bottom: 6px; text-transform: uppercase; letter-spacing: .04em; }
.links-head svg { width: 15px; height: 15px; }
.link-list { list-style: none; margin: 0; padding: 0; }
.link-list a { display: flex; gap: 12px; padding: 10px; margin: 0 -10px; border-radius: 10px; text-decoration: none; color: var(--text); transition: background .15s; }
.link-list a:hover { background: var(--hover); }
.link-list img { width: 18px; height: 18px; border-radius: 4px; margin-top: 2px; flex-shrink: 0; }
.lk { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.lt { font-size: 15px; font-weight: 500; color: var(--text-strong); line-height: 1.35; }
.link-list a:hover .lt { color: var(--accent); }
.lh { font-size: 12.5px; color: var(--muted); }
.ls { font-size: 13.5px; color: var(--muted); line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.actions { display: flex; gap: 2px; margin-top: 6px; opacity: 0; transition: opacity .2s; }
.msg.assistant:hover .actions, .msg.assistant:last-child .actions { opacity: 1; }
.actions button { border: 0; background: none; padding: 6px; border-radius: 7px; color: var(--muted); display: flex; align-items: center; gap: 6px; font-size: 12.5px; }
.actions button:hover { background: var(--hover); color: var(--text-strong); }
.actions svg { width: 16px; height: 16px; }

.caret { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--accent); margin-left: 3px; vertical-align: 1px; animation: pulse 1s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .3; transform: scale(.8); } }
.error-box { font-family: var(--sans); font-size: 14px; color: #B3261E; background: #FCEEEE; border: 1px solid #F1C8C5; padding: 10px 14px; border-radius: 10px; }

/* ---------- Composer ---------- */
.composer-wrap { padding: 0 24px 14px; flex-shrink: 0; }
.composer { max-width: var(--col); margin: 0 auto; background: var(--surface); border: 1px solid var(--border-strong); border-radius: 22px; box-shadow: var(--shadow); padding: 14px 14px 10px 18px; transition: border-color .15s, box-shadow .15s; }
.composer:focus-within { border-color: var(--focus); box-shadow: var(--shadow), 0 0 0 3px rgba(210, 105, 63, .08); }
.composer textarea { width: 100%; border: 0; outline: 0; resize: none; background: transparent; color: var(--text-strong); font: 16px/1.5 var(--sans); max-height: 220px; min-height: 26px; }
.composer textarea::placeholder { color: var(--muted); }
.composer-bar { display: flex; align-items: center; justify-content: space-between; margin-top: 8px; }
.chip-web { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--accent); background: var(--accent-soft); padding: 5px 10px; border-radius: 999px; font-weight: 500; }
.chip-web svg { width: 15px; height: 15px; }
.send { width: 34px; height: 34px; border-radius: 10px; border: 0; background: var(--accent); color: #fff; display: grid; place-items: center; transition: background .15s, opacity .15s; }
.send:hover:not(:disabled) { background: var(--accent-hover); }
.send:disabled { opacity: .4; cursor: default; }
.send svg { stroke-width: 2.4; }
.send .i-stop { display: none; fill: currentColor; stroke: none; }
.app.busy .send .i-send { display: none; }
.app.busy .send .i-stop { display: block; }
.app.busy .send { opacity: 1; }

.suggestions { max-width: var(--col); margin: 16px auto 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.suggestions button { border: 1px solid var(--border); background: transparent; padding: 7px 14px; border-radius: 10px; font-size: 13.5px; color: var(--muted); }
.suggestions button:hover { background: var(--surface); color: var(--text-strong); border-color: var(--border-strong); }
.disclaimer { text-align: center; color: var(--muted); font-size: 12px; margin: 10px 0 0; }
#quota { color: var(--accent); font-weight: 600; }
.app.empty .disclaimer:has(#quota:not([hidden])) { display: block; }

/* ---------- Mobile ---------- */
.scrim { display: none; }
@media (max-width: 860px) {
  .only-mobile { display: grid; }
  .sidebar { position: fixed; inset: 0 auto 0 0; z-index: 30; transform: translateX(-100%); transition: transform .25s ease; box-shadow: var(--shadow); }
  .app.side-open .sidebar { transform: none; }
  .app.side-open .scrim { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.25); z-index: 20; }
  .messages { padding: 8px 16px 32px; }
  .composer-wrap { padding: 0 12px calc(10px + env(safe-area-inset-bottom)); }
  .app.empty .thread { margin-top: 16vh; }
  .msg.assistant .body { font-size: 16.5px; }
}

/* Logo acima da saudação (só no celular) */
.welcome { flex-direction: column; align-items: center; }
.welcome-logo { display: none; height: 48px; width: auto; margin-bottom: 20px; }
@media (max-width: 860px) {
  .welcome-logo.logo-light { display: block; }
  .app.empty .thread { margin-top: 10vh; }
  .greet-dot { display: none; }
}
@media (max-width: 860px) and (prefers-color-scheme: dark) {
  .welcome-logo.logo-light { display: none; }
  .welcome-logo.logo-dark { display: block; }
}

/* Últimas buscas */
.suggestions { align-items: center; }
.sugg-label { width: 100%; text-align: center; font-size: 12px; color: var(--muted); margin-bottom: 2px; }
.sugg { display: inline-flex; align-items: center; border: 1px solid var(--border); border-radius: 10px; max-width: 100%; transition: background .15s, border-color .15s; }
.sugg:hover { background: var(--surface); border-color: var(--border-strong); }
.sugg-q { display: inline-flex; align-items: center; gap: 6px; border: 0; background: none; padding: 7px 12px; font-size: 13.5px; color: var(--muted); min-width: 0; max-width: 280px; }
.sugg-q span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sugg-q svg { width: 14px; height: 14px; flex-shrink: 0; }
.sugg:hover .sugg-q { color: var(--text-strong); }
.sugg-x { border: 0; background: none; color: var(--muted); font-size: 16px; line-height: 1; padding: 0 10px 0 0; opacity: .5; }
.sugg-x:hover { opacity: 1; color: var(--text-strong); }

/* Botão Entrar */
.login { position: relative; padding: 0 0 10px; }
.login-btn { width: 100%; display: flex; align-items: center; gap: 10px; border: 1px solid var(--border-strong); background: var(--surface); color: var(--text-strong); padding: 9px 12px; border-radius: 10px; font-weight: 500; transition: border-color .15s, background .15s; }
.login-btn:hover { border-color: var(--accent); }
.login-btn .chev { margin-left: auto; width: 16px; height: 16px; color: var(--muted); transition: transform .2s; }
.login-btn[aria-expanded="true"] .chev { transform: rotate(180deg); }
.login-menu { position: absolute; left: 0; right: 0; top: calc(100% - 4px); z-index: 10; background: var(--surface); border: 1px solid var(--border-strong); border-radius: 12px; box-shadow: var(--shadow); padding: 6px; }
.login-menu a { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 8px; text-decoration: none; color: var(--text-strong); }
.login-menu a:hover { background: var(--hover); }
.login-menu img { width: 28px; height: 28px; border-radius: 7px; background: var(--bg); padding: 3px; }
.login-menu span { display: flex; flex-direction: column; line-height: 1.25; }
.login-menu strong { font-size: 14px; font-weight: 600; }
.login-menu small { font-size: 12px; color: var(--muted); }
.suggestions .sugg-q, .suggestions .sugg-x { border: 0; border-radius: 0; background: none; }
.suggestions .sugg-q { padding: 7px 12px; }
.suggestions .sugg-x { padding: 0 10px 0 0; }

/* Rodapé: instalar o app */
.app-footer { text-align: center; margin-top: 6px; }
.install-link { display: inline-flex; align-items: center; gap: 6px; border: 0; background: none; color: var(--muted); font-size: 12.5px; padding: 4px 8px; border-radius: 8px; }
.install-link:hover { color: var(--accent); background: var(--hover); }
.install-link svg { width: 14px; height: 14px; }
.app.empty .app-footer { margin-top: 18px; }

/* Tutorial de instalação (PWA) */
.pwa-overlay { position: fixed; inset: 0; z-index: 50; background: rgba(20, 18, 14, .45); display: flex; align-items: center; justify-content: center; padding: 16px; animation: pwa-fade .2s ease; }
.pwa-overlay[hidden] { display: none; }
.pwa-sheet { position: relative; width: 100%; max-width: 460px; max-height: calc(100dvh - 32px); overflow-y: auto; background: var(--surface); color: var(--text); border: 1px solid var(--border); border-radius: 20px; box-shadow: 0 20px 60px rgba(0,0,0,.25); padding: 22px 22px 18px; font-family: var(--sans); animation: pwa-up .25s ease; }
.pwa-close { position: absolute; top: 10px; right: 12px; border: 0; background: none; font-size: 24px; line-height: 1; color: var(--muted); padding: 6px; border-radius: 8px; }
.pwa-close:hover { background: var(--hover); color: var(--text-strong); }
.pwa-head { display: flex; gap: 14px; align-items: center; padding-right: 26px; }
.pwa-appicon { width: 56px; height: 56px; border-radius: 14px; box-shadow: 0 1px 4px rgba(0,0,0,.12); flex-shrink: 0; }
.pwa-head h2 { margin: 0; font-family: var(--serif); font-weight: 500; font-size: 21px; color: var(--text-strong); }
.pwa-head p { margin: 3px 0 0; font-size: 13.5px; color: var(--muted); line-height: 1.4; }
.pwa-tabs { display: flex; gap: 4px; margin: 18px 0 8px; background: var(--bg); border: 1px solid var(--border); border-radius: 12px; padding: 4px; }
.pwa-tabs button { flex: 1; border: 0; background: none; padding: 8px 6px; border-radius: 9px; font-size: 13.5px; font-weight: 500; color: var(--muted); }
.pwa-tabs button[aria-selected="true"] { background: var(--surface); color: var(--text-strong); box-shadow: 0 1px 3px rgba(0,0,0,.08); }
.pwa-detected { font-size: 12px; color: var(--accent); font-weight: 600; margin: 18px 2px 6px; text-transform: uppercase; letter-spacing: .04em; }
.pwa-steps { margin: 0; padding: 0; list-style: none; counter-reset: s; }
.pwa-steps li { counter-increment: s; position: relative; padding: 9px 0 9px 38px; font-size: 14.5px; line-height: 1.5; border-bottom: 1px solid var(--border); }
.pwa-steps li:last-child { border-bottom: 0; }
.pwa-steps li::before { content: counter(s); position: absolute; left: 0; top: 9px; width: 26px; height: 26px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); font-weight: 700; font-size: 13px; display: grid; place-items: center; }
.pwa-steps b { color: var(--text-strong); font-weight: 600; }
.pwa-ico { width: 18px; height: 18px; vertical-align: -4px; margin: 0 2px; color: var(--accent); }
.pwa-note { font-size: 12.5px; color: var(--muted); background: var(--bg); border-radius: 10px; padding: 10px 12px; margin: 10px 0 0; line-height: 1.5; }
.pwa-note .pwa-ico { width: 15px; height: 15px; vertical-align: -3px; }
.pwa-ok { width: 100%; margin-top: 16px; border: 0; background: var(--accent); color: #fff; font-weight: 600; font-size: 15px; padding: 12px; border-radius: 12px; }
.pwa-ok:hover { background: var(--accent-hover); }
@keyframes pwa-fade { from { opacity: 0; } }
@keyframes pwa-up { from { opacity: 0; transform: translateY(14px); } }
@media (max-width: 860px) {
  .pwa-overlay { align-items: flex-end; padding: 0; }
  .pwa-sheet { max-width: none; border-radius: 20px 20px 0 0; padding-bottom: calc(18px + env(safe-area-inset-bottom)); }
}

/* Sem a etiqueta "Web" no campo de pesquisa */
.chip-web { display: none; }
.composer-bar { justify-content: flex-end; }

/* Caixa de busca em uma linha: texto e botão lado a lado */
.composer { display: flex; align-items: flex-end; gap: 10px; padding: 9px 9px 9px 18px; border-radius: 18px; }
.composer textarea { flex: 1; padding: 6px 0; min-height: 36px; }
.composer-bar { margin-top: 0; flex-shrink: 0; }
.send { width: 36px; height: 36px; }

/* Popup "Instalar Poosting IA" */
.pwa-pill { width: max-content; max-width: calc(100vw - 24px); position: fixed; right: 18px; bottom: 18px; z-index: 40; display: flex; align-items: center; background: var(--surface); border: 1px solid var(--border-strong); border-radius: 16px; box-shadow: 0 6px 24px rgba(40, 30, 10, .14); opacity: 0; transform: translateY(16px); pointer-events: none; transition: opacity .3s ease, transform .3s ease; }
.pwa-pill.show { opacity: 1; transform: none; pointer-events: auto; }
.pwa-pill-main { display: flex; align-items: center; gap: 10px; border: 0; background: none; padding: 8px 4px 8px 8px; text-align: left; font-family: var(--sans); }
.pwa-pill-main img { width: 36px; height: 36px; border-radius: 10px; box-shadow: 0 1px 3px rgba(0,0,0,.12); }
.pwa-pill-main span { display: flex; flex-direction: column; line-height: 1.25; white-space: nowrap; }
.pwa-pill-main strong { font-size: 14px; font-weight: 600; color: var(--text-strong); }
.pwa-pill-main small { font-size: 12px; color: var(--muted); }
.pwa-pill-main:hover strong { color: var(--accent); }
.pwa-pill-x { border: 0; background: none; color: var(--muted); font-size: 18px; line-height: 1; padding: 8px 12px 8px 8px; border-radius: 10px; }
.pwa-pill-x:hover { color: var(--text-strong); }
@media (max-width: 860px) {
  .pwa-pill { left: 50%; right: auto; transform: translate(-50%, 16px); bottom: calc(96px + env(safe-area-inset-bottom)); }
  .pwa-pill.show { transform: translate(-50%, 0); }
  .app.empty .pwa-pill { bottom: calc(18px + env(safe-area-inset-bottom)); }
}

/* Links dos termos */
.disclaimer a { color: var(--muted); text-decoration: underline; text-underline-offset: 2px; }
.disclaimer a:hover { color: var(--accent); }
.terms-link { display: none; font-size: 12px; color: var(--muted); text-decoration: none; margin-left: 6px; }
.terms-link:hover { color: var(--accent); text-decoration: underline; }
.app.empty .terms-link { display: inline; }
