/* ============================================================
   Praça 21 — mercado nocturno
   fundo slate profundo · dourado-sat · price tags de feira
   ============================================================ */
:root {
  --bg: #131820;
  --surface: #1b222d;
  --surface-2: #222b38;
  --line: #2c3745;
  --text: #e9edf3;
  --muted: #8b98a9;
  --gold: #f2a93b;
  --gold-deep: #c9820f;
  --blue: #7fa6c9;
  --green: #5fbf7a;
  --red: #e06a5e;
  --radius: 14px;
}
* { box-sizing: border-box; margin: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  min-height: 100dvh;
  display: flex; flex-direction: column;
}
a { color: var(--gold); text-decoration: none; }
img { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }

/* ---------- Topo ---------- */
.topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: .9rem 1rem .6rem;
}
.brand {
  color: var(--text); font-weight: 800; font-size: 1.35rem; letter-spacing: -.02em;
}
.brand em { font-style: normal; color: var(--gold); }
.brand-mark {
  display: inline-block; width: 1.6em; height: 1.6em;
  vertical-align: -.36em; margin-right: .35rem; border-radius: 6px;
}
.hello { color: var(--muted); font-size: .85rem; }
.hello:hover { color: var(--text); }
.exit {
  color: var(--muted); font-size: .8rem; border: 1px solid var(--line);
  border-radius: 8px; padding: .22rem .55rem; white-space: nowrap;
  background: none; cursor: pointer; font-family: inherit; line-height: 1.4;
}
.exit:hover { color: var(--red); border-color: var(--red); }
/* Formulário reduzido a um simples botão-link (usado no logout via POST) */
.linkform { display: inline; margin: 0; }
.linkbtn {
  background: none; border: 0; padding: 0; cursor: pointer;
  font: inherit; color: var(--gold); text-decoration: underline;
}
.linkbtn:hover { color: var(--text); }

/* ---------- Navegação ---------- */
.topbar-right { display: flex; align-items: center; gap: .6rem; }
.navtoggle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 2.4rem; height: 2.4rem; font-size: 1.25rem; line-height: 1;
  background: var(--surface-2); border: 1px solid var(--line); color: var(--text);
  border-radius: 10px; cursor: pointer; position: relative;
}
/* Badge de não-lidas no hambúrguer (mesmo estilo do das mensagens) */
.nav-badge { position: absolute; top: -6px; right: -6px; box-shadow: 0 0 0 2px var(--bg); }
/* Mobile: menu escondido, aberto pelo hambúrguer (coluna) */
.mainnav {
  display: none; flex-direction: column; gap: .15rem;
  padding: .4rem .75rem .6rem; border-bottom: 1px solid var(--line); background: var(--bg);
}
.mainnav.open { display: flex; }
.mainnav::-webkit-scrollbar { display: none; }
.mainnav a {
  color: var(--muted); padding: .6rem .8rem; border-radius: 10px;
  font-size: .98rem; display: flex; align-items: center; gap: .5rem;
}
.mainnav a.on { background: var(--surface-2); color: var(--text); }

/* Desktop: menu horizontal fixo, sem hambúrguer */
@media (min-width: 640px) {
  .navtoggle { display: none; }
  .mainnav {
    display: flex; flex-direction: row; gap: .25rem; overflow-x: auto;
    padding: 0 .75rem .5rem; position: sticky; top: 0; z-index: 20;
  }
  .mainnav a { border-radius: 999px; padding: .5rem .8rem; white-space: nowrap; font-size: .95rem; }
}
.mainnav .ico { opacity: .8; }
.badge {
  background: var(--gold); color: #17110a; font-size: .72rem; font-weight: 700;
  border-radius: 999px; padding: 0 .45em; min-width: 1.5em; text-align: center;
}

/* ---------- Layout ---------- */
.wrap { flex: 1; width: 100%; max-width: 860px; margin: 0 auto; padding: 1rem; overflow-wrap: break-word; }
.foot {
  display: flex; flex-wrap: wrap; gap: .5rem 1rem; justify-content: space-between;
  color: var(--muted); font-size: .78rem; padding: 1rem; border-top: 1px solid var(--line);
  max-width: 860px; margin: 0 auto; width: 100%;
}
.btc-ticker { color: var(--gold); }
.foot .donate { width: 100%; }
.foot .donate > summary { color: var(--gold); font-weight: 700; cursor: pointer; padding: .3rem 0; }
.foot .donate .pay-body { display: flex; flex-wrap: wrap; gap: 1.2rem; justify-content: center; margin-top: .6rem; }
.foot .donate .hint { flex-basis: 100%; text-align: center; }
.page-title { font-size: 1.4rem; font-weight: 800; letter-spacing: -.02em; margin-bottom: .8rem; }
.sub-title { font-size: 1.05rem; font-weight: 700; margin: 1.4rem 0 .6rem; color: var(--blue); }

.flash {
  background: color-mix(in srgb, var(--green) 15%, var(--surface));
  border: 1px solid var(--green); color: var(--text);
  padding: .7rem 1rem; border-radius: var(--radius); margin-bottom: 1rem; font-size: .92rem;
}
.flash.err { background: color-mix(in srgb, var(--red) 15%, var(--surface)); border-color: var(--red); }

/* ---------- Cartões e formulários ---------- */
.card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 1rem; margin-bottom: 1rem;
}
.form label { display: block; margin-bottom: .9rem; font-size: .88rem; color: var(--muted); }
.form input, .form select, .form textarea, .filters input, .filters select,
.manage-row input, .manage-row select {
  width: 100%; margin-top: .3rem;
  background: var(--bg); border: 1px solid var(--line); border-radius: 10px;
  padding: .65rem .8rem; color: var(--text);
}
.form textarea { resize: vertical; }
.form input:focus, .form textarea:focus, .form select:focus,
.filters input:focus, .chat-form textarea:focus {
  outline: 2px solid var(--gold); outline-offset: 1px; border-color: transparent;
}
.hint { display: block; color: var(--muted); font-size: .8rem; margin: .2rem 0 .8rem; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
  background: var(--surface-2); border: 1px solid var(--line); color: var(--text);
  border-radius: 10px; padding: .6rem 1rem; cursor: pointer; font-weight: 600; font-size: .95rem;
}
.btn.primary { background: var(--gold); border-color: var(--gold-deep); color: #17110a; }
.btn.danger { background: transparent; border-color: var(--red); color: var(--red); }
.btn.tiny { padding: .25rem .6rem; font-size: .8rem; border-radius: 8px; }
.btn.wide { width: 100%; }
.btn:active { transform: translateY(1px); }

/* Input de ficheiros (fotos) — vestir o botão nativo "Choose Files" com o tema */
input[type=file] { color: var(--muted); font-size: .9rem; max-width: 100%; }
input[type=file]::file-selector-button {
  margin-right: .7rem;
  background: var(--surface-2); border: 1px solid var(--line); color: var(--text);
  border-radius: 10px; padding: .55rem .9rem; cursor: pointer;
  font-weight: 600; font-size: .9rem; font-family: inherit;
}
input[type=file]::file-selector-button:hover { border-color: var(--gold); color: var(--gold); }

/* Segmentado aluguer/serviço */
.seg { display: flex; gap: .5rem; margin-bottom: 1rem; }
.seg-opt { flex: 1; }
.seg-opt input { position: absolute; opacity: 0; }
.seg-opt span {
  display: block; text-align: center; padding: .55rem; border-radius: 10px;
  border: 1px solid var(--line); background: var(--bg); color: var(--muted); font-weight: 600;
}
.seg-opt input:checked + span { background: var(--gold); color: #17110a; border-color: var(--gold-deep); }
.seg-opt input:focus-visible + span { outline: 2px solid var(--gold); }

.price-set { border: 1px dashed var(--line); border-radius: var(--radius); padding: .8rem; margin-bottom: 1rem; }
.price-set legend { padding: 0 .4rem; color: var(--muted); font-size: .85rem; }
.price-inputs { display: grid; grid-template-columns: 1fr auto 1.3fr; gap: .5rem; align-items: center; }
.price-inputs input, .price-inputs select {
  background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: .6rem; color: var(--text); width: 100%;
}
/* Preço sempre em euros (mostra €); a unidade só aparece em aluguer/serviço */
.eur-tag { align-self: center; color: var(--gold); font-weight: 800; font-size: 1.25rem; }
.price-set.venda .price-inputs { grid-template-columns: 1fr auto; }
.price-set.venda .unit-wrap { display: none; }

/* Aviso do admin na página de anúncios */
.aviso {
  background: color-mix(in srgb, var(--gold) 12%, var(--surface));
  border: 1px solid var(--gold-deep); border-left-width: 4px;
  border-radius: var(--radius); padding: .75rem 1rem; margin-bottom: 1rem;
  color: var(--text); font-size: .92rem;
}

/* ---------- Manutenção + jogos ---------- */
.maint { max-width: 560px; margin: 1rem auto; text-align: center; }
.maint-emoji { font-size: 3rem; line-height: 1; }
.maint-msg { color: #c6cedb; margin: .6rem 0 1rem; white-space: pre-line; }
.games { margin: 1.5rem 0; }
.games-menu { display: flex; gap: .5rem; flex-wrap: wrap; justify-content: center; margin-bottom: 1rem; }
.games-menu .btn.on { background: var(--gold); border-color: var(--gold-deep); color: #17110a; }
.game-area { display: flex; justify-content: center; }
.g-galo, .g-mem, .g-snake { display: flex; flex-direction: column; align-items: center; gap: .7rem; }
.g-status { color: var(--muted); font-weight: 600; }
.galo-grid { display: grid; grid-template-columns: repeat(3, 64px); gap: 6px; }
.galo-cell { width: 64px; height: 64px; font-size: 1.9rem; background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; cursor: pointer; }
.mem-grid { display: grid; grid-template-columns: repeat(4, 62px); gap: 6px; }
.mem-card { width: 62px; height: 62px; font-size: 1.7rem; background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; cursor: pointer; }
.mem-card.done { opacity: .35; }
.snake-cv { background: #131820; border: 1px solid var(--line); border-radius: 10px; max-width: 100%; touch-action: none; }
.snake-pad { display: flex; gap: .4rem; justify-content: center; }
.check-row { display: flex; align-items: center; gap: .5rem; }
.check-row input { width: auto; margin: 0; }

/* ---------- Filtros ---------- */
.filters { margin-bottom: 1rem; }
.filters input[type=search] { margin-bottom: .5rem; }
/* Mobile: filtros empilhados na vertical (texto legível) */
.filter-row { display: flex; flex-direction: column; gap: .5rem; }
.filter-row select { width: 100%; }
@media (min-width: 640px) {
  .filter-row { flex-direction: row; }
  .filter-row select { flex: 1; }
}

/* ---------- Grelha de anúncios ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: .75rem; }
.tile {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; color: var(--text); display: flex; flex-direction: column;
  transition: border-color .15s;
}
.tile:hover { border-color: var(--gold); }
.tile-img { aspect-ratio: 4/3; background: var(--surface-2); position: relative; display: grid; place-items: center; }
.tile-img img { width: 100%; height: 100%; object-fit: cover; }
.noimg { font-size: 2.2rem; opacity: .5; }
.is-reservado .tile-img img { filter: grayscale(.7) brightness(.7); }
.ribbon {
  position: absolute; top: .5rem; left: -.4rem; background: var(--blue); color: #0e1520;
  font-size: .7rem; font-weight: 700; padding: .15rem .6rem; border-radius: 0 6px 6px 0;
}
.tile-body { padding: .6rem .7rem .7rem; display: flex; flex-direction: column; gap: .3rem; }
.tile-body h3 { font-size: .92rem; font-weight: 600; line-height: 1.3; }
.owner { color: var(--muted); font-size: .76rem; }

.chip {
  display: inline-block; font-size: .68rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: .05em; padding: .12rem .5rem; border-radius: 999px;
  background: var(--surface-2); color: var(--muted); width: fit-content;
}
.chip-aluguer { background: color-mix(in srgb, var(--blue) 22%, transparent); color: var(--blue); }
.chip-servico { background: color-mix(in srgb, var(--green) 20%, transparent); color: var(--green); }
.chip-estado, .chip-reservado { background: color-mix(in srgb, var(--gold) 20%, transparent); color: var(--gold); }
.chip-ativo { background: color-mix(in srgb, var(--green) 20%, transparent); color: var(--green); }
.chip-concluido { background: var(--surface-2); color: var(--muted); }

/* Price tag — etiqueta de feira */
.price-tag {
  font-weight: 800; color: var(--gold); font-size: .98rem;
  display: flex; align-items: baseline; gap: .45rem; flex-wrap: wrap;
}
.price-tag.big { font-size: 1.5rem; margin: .3rem 0 .8rem; }
.btc-eq { color: var(--muted); font-weight: 500; font-size: .74em; }
.btc-eq:not(:empty)::before { content: "≈ "; }

/* ---------- Detalhe ---------- */
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: .5rem; margin-bottom: .9rem; }
.gallery img { width: 100%; height: 160px; border-radius: var(--radius); object-fit: cover; cursor: zoom-in; }
/* Se só houver uma foto, ocupa a largura toda e mais alta */
.gallery img:only-child { height: 300px; grid-column: 1 / -1; }

/* Lightbox — ver imagem em grande */
.lightbox { position: fixed; inset: 0; background: rgba(0,0,0,.9); display: none; align-items: center; justify-content: center; padding: 1rem; z-index: 50; cursor: zoom-out; }
.lightbox.on { display: flex; }
.lightbox img { max-width: 100%; max-height: 100%; border-radius: var(--radius); object-fit: contain; }

/* Admin — membros */
#memberSearch {
  width: 100%; background: var(--bg); color: var(--text);
  border: 1px solid var(--line); border-radius: 10px; padding: .65rem .8rem;
}
#memberSearch:focus { outline: 2px solid var(--gold); outline-offset: 1px; border-color: transparent; }
.member-toggle { cursor: pointer; display: inline-block; user-select: none; }
.member-toggle:hover strong { color: var(--gold); }
.member-toggle .caret { color: var(--muted); font-size: .8em; }
tbody.member.inactive { opacity: .55; }
.member-detail td { color: var(--muted); background: var(--bg); font-size: .85rem; }
.member-detail strong { color: var(--text); }
.detail-head { display: flex; gap: .4rem; flex-wrap: wrap; margin-bottom: .5rem; }
.detail-title { font-size: 1.35rem; font-weight: 800; letter-spacing: -.02em; margin-bottom: .3rem; overflow-wrap: anywhere; }
.descr { white-space: pre-line; color: #c6cedb; margin-bottom: 1rem; overflow-wrap: anywhere; }

.owner-card { display: flex; flex-direction: column; gap: .8rem; }
.owner-info { display: flex; align-items: center; gap: .7rem; }
.owner-info small { display: block; color: var(--muted); font-size: .78rem; }
.owner-avatar {
  width: 2.6rem; height: 2.6rem; border-radius: 50%; background: var(--surface-2);
  color: var(--gold); font-weight: 800; display: grid; place-items: center; flex-shrink: 0;
  border: 1px solid var(--line);
}
.owner-avatar.xl { width: 3.4rem; height: 3.4rem; font-size: 1.3rem; }

.pay summary { cursor: pointer; font-weight: 700; color: var(--gold); padding: .3rem 0; }
.pay-body { display: flex; flex-direction: column; gap: 1rem; padding-top: .8rem; }
.pay-block { display: flex; flex-direction: column; align-items: center; gap: .5rem; text-align: center; }
.pay-block small { color: var(--muted); text-transform: uppercase; letter-spacing: .06em; font-size: .7rem; }
.qr { background: #fff; padding: 10px; border-radius: 12px; }
.qr img, .qr canvas { width: 180px !important; height: 180px !important; }

/* Ligar Telegram (botão + QR) */
.tg-link { max-width: 520px; }
.tg-steps { text-align: center; }
.tg-steps p { margin: .6rem 0; }
.tg-steps .btn.wide { margin: .4rem 0; }
.tg-qr { display: inline-block; margin: .6rem auto; }
.tg-or { display: flex; align-items: center; gap: .8rem; margin: 1.1rem 0; color: var(--muted); font-size: .8rem; text-transform: uppercase; letter-spacing: .05em; }
.tg-or::before, .tg-or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.addr {
  font-size: .72rem; word-break: break-all; background: var(--bg);
  padding: .4rem .6rem; border-radius: 8px; border: 1px solid var(--line); max-width: 100%;
}

.pw-reset { border-color: var(--gold); }
.pw-reset strong { display: block; margin-bottom: .5rem; }
.pw-reset-row { display: flex; gap: .5rem; align-items: center; margin-bottom: .4rem; }
.pw-reset .addr { font-size: 1rem; letter-spacing: .04em; font-weight: 700; color: var(--gold); }

.video-wrap { position: relative; margin: 1rem 0; aspect-ratio: 16 / 9; }
.video-wrap iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; border-radius: 12px; background: #000; }
.draft-note { border-color: var(--gold); display: flex; flex-direction: column; gap: .6rem; }
.draft-note strong { color: var(--gold); }
.chip-rascunho { background: transparent; border: 1px dashed var(--line); color: var(--muted); }

.manage strong { display: block; margin-bottom: .6rem; }
.manage-row { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; }
.manage-row select { width: auto; flex: 1; min-width: 8rem; }

/* ---------- Mensagens ---------- */
.thread-list { display: flex; flex-direction: column; gap: .5rem; }
.thread {
  display: flex; align-items: center; gap: .7rem; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--radius); padding: .7rem .8rem; color: var(--text);
}
.thread.unread { border-color: var(--gold); }
.thread-mid { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.thread-title { color: var(--blue); font-size: .78rem; }
.thread-last { color: var(--muted); font-size: .8rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.chat-head { display: flex; align-items: center; gap: .7rem; margin-bottom: .8rem; }
.chat-head .back { font-size: 1.6rem; line-height: 1; color: var(--muted); padding: .2rem .5rem; }
.chat-listing { display: block; font-size: .8rem; }
.chat { display: flex; flex-direction: column; gap: .5rem; padding-bottom: 1rem; min-height: 40vh; }
.msg { max-width: 82%; padding: .55rem .8rem; border-radius: 14px; font-size: .95rem; }
.msg p { white-space: pre-line; }
.msg time { display: block; font-size: .66rem; color: var(--muted); margin-top: .2rem; }
.msg.me { align-self: flex-end; background: color-mix(in srgb, var(--gold) 26%, var(--surface)); border-bottom-right-radius: 4px; }
.msg.them { align-self: flex-start; background: var(--surface-2); border-bottom-left-radius: 4px; }
.empty-chat { color: var(--muted); font-size: .88rem; text-align: center; margin: auto; }
.chat-form {
  display: flex; gap: .5rem; position: sticky; bottom: 0; background: var(--bg);
  padding: .6rem 0 calc(.6rem + env(safe-area-inset-bottom));
}
.chat-form textarea {
  flex: 1; background: var(--surface); border: 1px solid var(--line);
  border-radius: 999px; padding: .6rem 1rem; resize: none; max-height: 6rem;
}
.chat-form .btn { border-radius: 50%; width: 2.9rem; height: 2.9rem; padding: 0; flex-shrink: 0; }

/* ---------- Perfil / admin ---------- */
.profile-head { display: flex; align-items: center; gap: .9rem; margin-bottom: 1rem; }
.profile-head .page-title { margin-bottom: 0; }
.mine { display: flex; flex-direction: column; gap: .5rem; }
.mine-row {
  display: flex; align-items: center; gap: .7rem; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--radius); padding: .55rem .7rem; color: var(--text);
}
.mine-thumb { width: 3rem; height: 3rem; border-radius: 10px; overflow: hidden; background: var(--surface-2); display: grid; place-items: center; flex-shrink: 0; }
.mine-thumb img { width: 100%; height: 100%; object-fit: cover; }
.mine-mid { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.mine-mid small { color: var(--gold); font-size: .8rem; }
.logout-row { margin-top: 1.5rem; }

.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: .6rem; margin-bottom: 1rem; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: .8rem; text-align: center; }
.stat strong { display: block; font-size: 1.5rem; color: var(--gold); }
.stat small { color: var(--muted); font-size: .76rem; }
.tbl { width: 100%; border-collapse: collapse; margin-top: .6rem; }
.tbl td { padding: .5rem .3rem; border-top: 1px solid var(--line); vertical-align: middle; font-size: .9rem; }
.tbl tr.inactive { opacity: .45; }
.ta-r { text-align: right; }
.thumbs { display: flex; gap: .5rem; flex-wrap: wrap; margin-bottom: .9rem; }
.thumb { position: relative; }
.thumb img { width: 4.5rem; height: 4.5rem; object-fit: cover; border-radius: 10px; }
.thumb-x {
  position: absolute; top: -6px; right: -6px; width: 1.4rem; height: 1.4rem;
  border-radius: 50%; background: var(--red); color: #fff; border: none; cursor: pointer; line-height: 1;
}

/* ---------- Auth ---------- */
.auth { max-width: 380px; margin: 8vh auto 0; }
.auth-title { font-size: 1.6rem; font-weight: 800; letter-spacing: -.02em; line-height: 1.25; margin-bottom: 1.2rem; }
.auth-title .accent { color: var(--gold); }
.auth-alt { text-align: center; color: var(--muted); font-size: .9rem; margin-top: 1rem; }

.empty { text-align: center; color: var(--muted); padding: 3rem 1rem; display: flex; flex-direction: column; gap: 1rem; align-items: center; }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
@media (min-width: 640px) {
  .grid { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
  .gallery img { height: 320px; }
}

/* ---------- Localização ---------- */
.chip-loc { background: color-mix(in srgb, var(--gold) 14%, transparent); color: var(--gold); text-transform: none; letter-spacing: 0; }
.loc-row { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; }
@media (max-width: 480px) { .loc-row { grid-template-columns: 1fr; } }

/* ---------- Seleção para colagem ---------- */
.thumb-sel { position: absolute; top: 4px; left: 4px; cursor: pointer; }
.thumb-sel input { position: absolute; opacity: 0; }
.thumb-sel span {
  display: grid; place-items: center; width: 1.4rem; height: 1.4rem;
  border-radius: 6px; background: rgba(19,24,32,.75); border: 1px solid var(--line);
  color: transparent; font-size: .8rem; font-weight: 800;
}
.thumb-sel input:checked + span { background: var(--gold); border-color: var(--gold-deep); color: #17110a; }
.thumb-sel input:focus-visible + span { outline: 2px solid var(--gold); }

/* ---------- Vendas e convites de membros ---------- */
.chip-venda { background: color-mix(in srgb, #b48ce0 22%, transparent); color: #b48ce0; }
.mini-title { font-size: .85rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin: 1rem 0 .5rem; }
.inv-row { display: inline-flex; gap: .3rem; align-items: center; margin-bottom: .3rem; }
.inv-row input { width: 3.6rem; background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: .25rem .4rem; color: var(--text); text-align: center; }

/* ---------- Como quer receber (publicar) ---------- */
.accept-set { border: 1px solid var(--line); border-radius: 12px; padding: .8rem 1rem; margin-bottom: 1rem; }
.accept-set legend { padding: 0 .4rem; color: var(--muted); font-size: .9rem; }
.accept-opts { display: flex; flex-wrap: wrap; gap: .6rem; margin-bottom: .5rem; }
.accept-opt { display: inline-flex; align-items: center; gap: .4rem; border: 1px solid var(--line); border-radius: 10px; padding: .45rem .7rem; cursor: pointer; }
.accept-opt input { accent-color: var(--gold); }

/* ---------- "Recebe em:" (anúncio) e ícones (feed) ---------- */
.accepts { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; margin: .2rem 0 .8rem; }
.accepts-label { color: var(--muted); font-size: .85rem; }
.acc-chip { display: inline-flex; align-items: center; gap: .25rem; background: var(--surface-2); border: 1px solid var(--line); border-radius: 999px; padding: .2rem .6rem; font-size: .85rem; }
.tile-accepts { display: inline-flex; gap: .25rem; margin-left: .4rem; }
.acc-ic { color: var(--gold); font-size: .95rem; cursor: help; }

/* ---------- Inserir pagamento + cartão no chat ---------- */
.paytoggle { padding: .5rem .7rem; }
.pay-insert { border: 1px solid var(--line); border-radius: 12px; padding: .7rem .8rem; margin-bottom: .5rem; display: flex; flex-direction: column; gap: .5rem; background: var(--surface); }
.pay-insert-kind { display: flex; gap: 1rem; }
.pay-insert-kind label { display: inline-flex; align-items: center; gap: .3rem; }
.pay-insert input[type=text] { background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: .5rem .6rem; color: var(--text); }
.paycard { margin-top: .5rem; border: 1px solid var(--gold-deep); border-radius: 10px; padding: .6rem .7rem; background: color-mix(in srgb, var(--gold) 10%, var(--surface)); }
.paycard-h { font-weight: 700; font-size: .9rem; margin-bottom: .3rem; }
.paycard-addr { display: block; word-break: break-all; font-size: .78rem; color: var(--muted); margin-bottom: .5rem; }
.paycard-actions { display: flex; flex-wrap: wrap; gap: .4rem; }
.paycard-qr { margin-top: .6rem; }
.paycard-qr img, .paycard-qr canvas { background: #fff; padding: 8px; border-radius: 8px; }
.paycard-warn { display: block; margin-top: .5rem; color: var(--muted); font-size: .74rem; }

/* ---------- Remover mensagem + report ---------- */
.msg-del-form { display: inline; margin: 0; }
.msg-del { background: none; border: 0; padding: 0; margin-top: .2rem; cursor: pointer; font: inherit; font-size: .7rem; color: var(--muted); text-decoration: underline; opacity: .7; }
.msg-del:hover { color: var(--red); opacity: 1; }
.msg.removed .msg-removed { color: var(--muted); font-style: italic; font-size: .82rem; }
.report-banner { background: color-mix(in srgb, var(--red) 14%, transparent); border: 1px solid var(--red); color: var(--text); border-radius: 10px; padding: .55rem .8rem; margin-bottom: .6rem; font-size: .85rem; }
.terminada-banner { background: color-mix(in srgb, var(--green) 14%, transparent); border: 1px solid var(--green); color: var(--text); border-radius: 10px; padding: .55rem .8rem; margin-bottom: .6rem; font-size: .85rem; }
.terminar-form { margin: .6rem 0 0; text-align: right; }
.report-box { margin-top: .8rem; border: 1px solid var(--line); border-radius: 12px; padding: .2rem .8rem; }
.report-box summary { cursor: pointer; color: var(--muted); padding: .5rem 0; font-size: .9rem; }
.report-box[open] summary { color: var(--red); }
.report-box textarea { width: 100%; background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: .5rem; color: var(--text); margin-bottom: .5rem; }

/* ---------- Vista de report (admin) ---------- */
.rep-thread { display: flex; flex-direction: column; gap: .6rem; }
.rep-msg { border: 1px solid var(--line); border-radius: 10px; padding: .5rem .7rem; }
.rep-msg-h { display: flex; gap: .5rem; align-items: baseline; font-size: .85rem; margin-bottom: .3rem; }
.rep-msg-h span { margin-left: auto; color: var(--muted); font-size: .78rem; font-variant-numeric: tabular-nums; }
.rep-msg p { margin: 0; white-space: pre-wrap; word-break: break-word; }
.rep-msg.rep-del { border-style: dashed; background: color-mix(in srgb, var(--red) 6%, transparent); }
.rep-del-note { color: var(--red); font-size: .76rem; margin-bottom: .3rem; }
