/* ==========================================================================
   Poostaki — main.css (padrão único e LIMPO)
   - Base (shared)
   - Feed (scoped)        body.page-feed
   - Perfil (scoped)      body.page-profile
   - Vitrine (scoped)     body.page-vitrine
   ========================================================================== */

/* =========================
   1) TOKENS / ROOT
   ========================= */
:root{
  /* Base */
  --bg-body:#081534;
  --bg-panel: rgba(15, 23, 42, 0.75);
  --bg-card: rgba(30, 41, 59, 0.4);
  --bg-hover: rgba(51, 65, 85, 0.5);
  --border: rgba(148, 163, 184, 0.1);

  --txt-primary:#f1f5f9;
  --txt-secondary:#94a3b8;

  --brand-primary:#06b6d4; /* ciano */
  --br-green:#009440;
  --br-yellow:#ffcb00;

  --nav-width: 275px;
  --center-width: 600px;
  --right-width: 350px;

  --header-height-desktop: 54px;

  --radius-lg: 16px;
  --radius-pill: 999px;

  /* Post separator */
  --post-sep-h: 1px;
  --post-sep-opacity: .50;

  /* Mobile nav */
  --mnav-bg: rgba(2, 6, 23, .78);
  --mnav-border: rgba(148, 163, 184, .12);
  
  --mnav-h: 56px;

  --mnav-icon: rgba(148, 163, 184, .95);
  --mnav-icon-active: #38bdf8;
  --mnav-active-bg: rgba(56, 189, 248, .12);

  --mnav-focus: rgba(56, 189, 248, .35);

  --msearch-bg: rgba(15, 23, 42, .92);
  --msearch-border: rgba(148, 163, 184, .14);

  --minput-bg: rgba(2, 6, 23, .55);
  --minput-border: rgba(148, 163, 184, .16);
  --minput-txt: rgba(226, 232, 240, .98);
  --minput-ph: rgba(148, 163, 184, .9);

  /* Chrome mobile hide/show */
  --chrome-ease: cubic-bezier(.2,.9,.2,1);
  --chrome-in:   .18s;
  --chrome-out:  .30s;
  --chrome-fade: .34s;
  --chrome-top-hide: -120%;
  --chrome-bot-hide:  120%;

  /* iOS browser chrome extra (se usar) */
  --ios-browser-h: 90px; /* ajuste 80~120 se precisar */
}

/* =========================
   PWA SAFE AREA (iOS)
   ========================= */
:root{
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);

  /* alturas “úteis” */
  --topbar-h: 38px;
  --mobile-nav-h:38px;
}

/***********************************************

toggle (claro/escuro)

***********************************************/
:root[data-theme="light"]{
  --bg-body:#f8fafc;
  --bg-panel: rgba(255,255,255,.78);
  --bg-card: rgba(255,255,255,.92);
  --bg-hover: rgba(15,23,42,.06);
  --border: rgba(15,23,42,.10);

  --txt-primary:#0f172a;
  --txt-secondary:#475569;

  /* Mobile nav no claro */
  --mnav-bg: rgba(248,250,252,.92);
  --mnav-border: rgba(15,23,42,.10);

  --mnav-icon: rgba(15,23,42,.72);
  --mnav-icon-active: #0284c7;
  --mnav-active-bg: rgba(2,132,199,.10);

  --mnav-focus: rgba(2,132,199,.25);

  --msearch-bg: rgba(255,255,255,.96);
  --msearch-border: rgba(15,23,42,.12);

  --minput-bg: rgba(15,23,42,.04);
  --minput-border: rgba(15,23,42,.12);
  --minput-txt: rgba(15,23,42,.92);
  --minput-ph: rgba(71,85,105,.85);
}


/* =========================
   2) RESET / BASE
   ========================= */
*{ box-sizing:border-box; }
html, body{
  height:100%;
  margin:0;
  background-color: var(--bg-body);
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: var(--txt-primary);
  overflow-x: hidden;
  overflow-y: hidden;   /* 👈 scroll só na .center */
}

body::-webkit-scrollbar{ width:0; background:transparent; }

body::before{
  content:"";
  position:fixed;
  inset:0;
  z-index:-1;
  background:
    radial-gradient(circle at 15% 50%, rgba(6, 182, 212, 0.05), transparent 25%),
    radial-gradient(circle at 85% 30%, rgba(16, 185, 129, 0.04), transparent 25%);
  pointer-events:none;
}

/* quando a busca estiver aberta, NÃO esconda topo nem composer */
body.search-open .page-feed main.center .topbar,
body.search-open .page-feed main.center .composer{
  transform: none !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}

body.ui-hide-chrome{
  padding-bottom: 0 !important;
}

body.ui-hide-chrome .mobile-nav{
  transform: translateY(110%);
  pointer-events: none;
  opacity: 0;
}

/* Quando esconder o chrome (topbar/tabs/nav), NÃO pode sobrar espaço */
body.page-feed.ui-hide-chrome .topbar,
body.page-feed.ui-hide-chrome .feed-tabs {
  transform: translateY(-120%);
  opacity: 0;
  pointer-events: none;
}

/* Mata o "buraco" de cima */
body.page-feed.ui-hide-chrome .center,
body.page-feed.ui-hide-chrome #centerScroll {
  padding-top: 8px !important; /* ajuste fino */
}

/* Esconde o nav de baixo sem quebrar layout */
body.page-feed.ui-hide-chrome .mobile-nav {
  transform: translateY(120%);
  opacity: 0;
  pointer-events: none;
}

/* Se você usa padding-bottom no body pra reservar o nav */
body.page-feed.ui-hide-chrome {
  padding-bottom: 0 !important;
}


a{ text-decoration:none; color:inherit; }
button{ font-family:inherit; -webkit-tap-highlight-color: transparent; }
button:focus{ outline:none; }
button:focus-visible{
  outline:2px solid rgba(6,182,212,0.45);
  outline-offset:2px;
}

/* textarea base (bem neutro) */
textarea{
  width:100%;
  border:none;
  background:transparent;
  resize:none;
  outline:none;
  color: var(--txt-primary);
  font-family: inherit;
}

/* =========================
   3) LAYOUT PRINCIPAL (shared)
   ========================= */
.app{
  display:grid;
  grid-template-columns: var(--nav-width) minmax(0, var(--center-width)) var(--right-width);
  gap:24px;

  max-width:1260px;
  width:100%;
  margin:0 auto;
  padding:0 16px;
  height:100%;
  justify-content:center;
}

.discover-card{
  width:min(520px, 92vw);
  max-height:80vh;
  overflow:hidden;              /* card não mostra barra */
}

.discover-list{
  max-height:55vh;              /* quem rola é só a lista */
  overflow:auto;
  padding-right:6px;
  scrollbar-width:none;         /* Firefox */
  -ms-overflow-style:none;      /* IE/Edge antigo */
}
.discover-list::-webkit-scrollbar{ width:0; height:0; } /* Chrome/Safari */


/* =========================
   4) SIDEBAR ESQUERDA (shared)
   ========================= */
.left{
  height:100%;
  padding-top:12px;
  padding-bottom:20px;
  display:flex;
  flex-direction:column;
  justify-content:space-between;
  overflow-y:auto;
}
.left::-webkit-scrollbar{ width:0; }

/* sidebar */
aside.left .nav a{ position:relative; }

/* ===== Donate Pix box (aside left) ===== */
.donate-box{
  margin-top: 12px;
  padding: 12px;
  border: 1px solid var(--border, rgba(255,255,255,.12));
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.55);
  backdrop-filter: blur(6px);
}

.donate-title{
  display:flex;
  align-items:center;
  gap:8px;
  font-weight: 800;
  font-size: 13px;
  letter-spacing: .2px;
  margin-bottom: 10px;
}

.donate-dot{
  width:10px;
  height:10px;
  border-radius:999px;
  background: #22c55e;
  box-shadow: 0 0 0 3px rgba(34,197,94,.15);
}

.donate-qr{
  display:flex;
  justify-content:center;
  margin-bottom: 10px;
}

.donate-qr img{
  width: 150px;
  height: 150px;
  object-fit: contain;
  border-radius: 12px;
  background: #fff;
  padding: 8px;
}

.donate-label{
    text-align: center;
  display:block;
  font-size: 16px;
  opacity: .85;
  margin: 6px 0 6px;
}

.donate-copy-row{
  display:flex;
  gap: 8px;
  align-items:center;
}

.donate-input{
  flex: 1;
  padding: 10px 10px;
  border-radius: 10px;
  border: 1px solid var(--border, rgba(255,255,255,.12));
  background: rgba(2, 6, 23, 0.35);
  color: inherit;
  font-size: 12px;
  outline: none;
}

.donate-btn{
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid var(--border, rgba(255,255,255,.12));
  background: rgba(59, 130, 246, 0.22);
  color: inherit;
  font-weight: 800;
  cursor: pointer;
  white-space: nowrap;
  width: 100%;
}

.donate-btn:active{ transform: translateY(1px); }

.donate-hint{
  margin-top: 8px;
  font-size: 12px;
  min-height: 16px;
  opacity: .9;
}

.donate-hint.ok{ color: #22c55e; }
.donate-hint.err{ color: #f97316; }


/* padrão (desktop/geral) - preso no ícone */
.nav-badge-dot{
  position:absolute;
  top:-2px;
  right:-2px;
  width:9px;
  height:9px;
  border-radius:999px;
  background:#22c55e;
  box-shadow:0 0 0 2px rgba(15, 23, 42, 0.95);
  pointer-events:none;
  z-index:3;
}

/* mobile: ajuste fino */
.mobile-nav .nav-badge-dot{
  top:6px;
  right:7px;
  box-shadow:
    0 0 0 3px rgba(34,197,94,.22),
    0 0 12px rgba(34,197,94,.65);
}

.mobile-nav a{ position:relative; }


.logo{
  font-size:26px;
  font-weight:800;
  letter-spacing:-0.5px;
  display:flex;
  align-items:center;
  gap:1px;
  color: var(--brand-primary);
  cursor:pointer;
}

.left .logo{ margin-bottom:24px; padding-left:12px; }

.eyes{
  display:inline-flex;
  gap:2px;
  transform: translateY(2px);
  margin:0 1px;
}
.eyes span{
  position:relative;
  width:12px;
  height:12px;
  background:#fff;
  border-radius:50%;
  box-shadow:0 0 12px rgba(6,182,212,0.4);
  animation: blink 4.5s infinite;
}
.eyes span::after{
  content:"";
  position:absolute;
  top:2px; left:2px;
  width:5px; height:5px;
  background:#0f172a;
  border-radius:50%;
}
@keyframes blink{
  0%,48%,52%,100%{ transform: scaleY(1); }
  50%{ transform: scaleY(0.1); }
}

.br-badge{
  font-size:9px;
  position:relative;
  top:-6px;
  left:2px;
  opacity:.75;
  letter-spacing:-0.5px;
}


.tab-badge.pop{ animation: pop .18s ease-out; }
@keyframes pop{
  from{ transform: translateY(-1px) scale(1.06); }
  to{ transform: translateY(-1px) scale(1); }
}


/* =========================
   NAV (desktop sidebar)
   ========================= */

/* Base do item do menu (links e botão logout, se existir) */
.nav a,
.logout-btn{
  display:flex;
  align-items:center;
  gap:10px;
  padding:12px 16px;
  margin-bottom:4px;
  border-radius: var(--radius-pill);
  font-size:19px;
  font-weight:500;
  color: var(--txt-primary);
  background: transparent;
  text-decoration:none;
  transition: background .2s, color .2s, filter .2s;
}

/* Hover e ativo */
.nav a:hover{ background: var(--bg-hover); }
.nav a.active{ font-weight:800; color: var(--brand-primary); }

/* Acessibilidade: foco no teclado */
.nav a:focus-visible,
.logout-btn:focus-visible{
  outline: 2px solid rgba(56, 189, 248, .75);
  outline-offset: 2px;
}

/* Botão logout (se usar <button> dentro de form) */
.logout-btn{
  border:0;
  cursor:pointer;
  width:100%;
  text-align:left;
}

/* =========================
   Selinho tipo “Em breve” dentro do texto (não é badge numérico no ícone)
   ========================= */
.nav-pill{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  margin-left:8px;
  padding:2px 8px;
  border-radius:999px;
  font-size:10px;
  font-weight:800;
  line-height:1;
  letter-spacing:.2px;
  background: rgba(148,163,184,.18);
  color: rgba(226,232,240,.95);
  border: 1px solid rgba(148,163,184,.20);
}
.nav-pill--soon{
  background: rgba(245,158,11,.12);
  border-color: rgba(245,158,11,.22);
  color: rgba(253,230,138,.95);
}

/* =========================
   NAV: suporte a .nav-ico e .nav-ico-anuncios (compat)
   ========================= */
.nav .nav-ico,
.nav .nav-ico-anuncios{
  position:relative;
  width:22px;
  height:22px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  flex:0 0 22px;
}

.nav .nav-ico svg,
.nav .nav-ico-anuncios svg{
  width:22px;
  height:22px;
  display:block;
  stroke-width:2px;
  position:relative;
  z-index:1; /* ícone abaixo do badge/dot */
}

/* =========================
   BADGE numérico (ex: 1, 9, 99+)
   ========================= */
.nav-badge{
  position:absolute;
  top:-6px;
  right:-8px;
  min-width:18px;
  height:18px;
  padding:0 6px;
  border-radius:999px;

  display:inline-flex;
  align-items:center;
  justify-content:center;

  font-size:11px;
  font-weight:800;
  line-height:1;

  color:#0b1220;
  background:#22c55e;
  box-shadow:0 0 0 2px rgba(15, 23, 42, 0.95);
  pointer-events:none;
  white-space:nowrap;

  z-index:3; /* 👈 garante visível */
}

.nav-badge--perfil{ background:#22c55e; }

.nav-badge.is-wide{
  font-size:10px;
  padding:0 7px;
}

/* Ativo: cor do ícone (se o SVG usa currentColor) */
.nav a.active svg{ color:#38bdf8; }

/* Link especial: admin */
.nav a.admin-link{
  color:#a5f3fc;
  background: rgba(6,182,212,0.10);
  border:1px solid rgba(6,182,212,0.18);
}
.nav a.admin-link:hover{ background: rgba(6,182,212,0.16); }

/* LOGOUT (verde) */
.nav a.nav-link-logout,
.logout-btn.logout-btn-logout{
  margin-top:10px;
  color:#98ff96;
}
.nav a.nav-link-logout:hover,
.logout-btn.logout-btn-logout:hover{
  background: rgba(152, 255, 150, 0.15);
  filter: brightness(1.05);
}

/* Ícones globais (mobile/topbar) */
.mobile-nav svg,
.topbar svg{
  width:22px;
  height:22px;
  flex:0 0 22px;
}


/* Se o menu colapsar, some o texto e o dot fica no ícone */
@media (max-width: 980px){
  .nav .nav-label{ display:none; }
}

/* Form logout (se existir)
   Evita duplicar espaçamento com o margin-top do link/botão */
.logout-form{ margin-top:0; }

/* =========================
   5) COLUNA CENTRAL (shared)
   ========================= */
.center{
  border-left:1px solid var(--border);
  border-right:1px solid var(--border);
  background: #081534 rgba(2, 6, 23, 0.3);
  height:100%;
  overflow-y:auto;      /* 👈 aqui sim */
  overflow-x:hidden;
  scroll-behavior:smooth;
  position:relative;
  padding-bottom:110px;
}

.center::-webkit-scrollbar{ width:6px; }
.center::-webkit-scrollbar-track{ background:transparent; }
.center::-webkit-scrollbar-thumb{ background:#334155; border-radius:10px; }

/* =========================
   6) COLUNA DIREITA (shared)
   ========================= */
.right{
  padding-top:12px;
  height:100%;
  overflow-y:auto;
}
.right::-webkit-scrollbar{ width:0; }

.search-box{
  background:#1e293b;
  border-radius: var(--radius-pill);
  padding:12px 20px;
  display:flex;
  align-items:center;
  gap:12px;
  color: var(--txt-secondary);
  margin-bottom:20px;
}
.search-box input{
  background:transparent;
  border:none;
  outline:none;
  color: var(--txt-primary);
  width:100%;
  font-size:16px;
}

.card{
  background: var(--bg-card);
  border:1px solid var(--border);
  border-radius: var(--radius-lg);
  margin-bottom:16px;
  overflow:hidden;
}
.card h3{
  margin:0;
  padding:16px;
  font-size:18px;
  font-weight:800;
  border-bottom:1px solid var(--border);
  position:sticky;
  top:0;
  background: rgba(30, 41, 59, 0.95);
  z-index:10;
}
.trend-item{
  padding:12px 16px;
  cursor:pointer;
  border-bottom:1px dashed rgba(255,255,255,0.05);
}
.trend-title{ font-weight:800; display:block; font-size:14px; }
.trend-meta{ font-size:12px; color: var(--txt-secondary); margin-top:2px; }

.top-poostaki-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin: 6px 0 14px;
}

.btn-clear-filter{
  display:inline-flex;
  align-items:center;
  padding:10px 12px;
  border-radius:12px;
  background: rgba(34,197,94,.12);
  border: 1px solid rgba(34,197,94,.25);
  color:#22c55e;
  font-weight:800;
  text-decoration:none;
}


/* =========================
   7) COMPONENTES REUSÁVEIS (shared)
   ========================= */
.avatar,
.avatar-small,
.reply-avatar{
  border-radius:50%;
  flex-shrink:0;
  background: linear-gradient(135deg, #334155, #0f1720);
  border:1px solid rgba(255,255,255,0.1);
  overflow:hidden;
  display:grid;
  place-items:center;
  line-height:1;
}
.avatar{ width:40px; height:40px; font-size:20px; }
.avatar-small{ width:40px; height:40px; font-size:26px; background:#334155; }
.reply-avatar{ width:30px; height:30px; font-size:14px; background:#334155; }

.avatar img,
.avatar-small img,
.reply-avatar img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}

.post{
  padding:16px;
  display:flex;
  gap:12px;
  border-bottom:1px solid rgba(251, 191, 36, 0.15);
  overflow-x:hidden;
  font-size: 16px;
  
}

.post.is-focus{
  outline: 2px solid rgba(34,197,94,.55);
  box-shadow: 0 0 0 6px rgba(34,197,94,.12), 0 0 30px rgba(34,197,94,.18);
  border-radius: 14px;
  animation: focusPulse 2.4s ease-out 1;
}
@keyframes focusPulse{
  0%{ box-shadow: 0 0 0 0 rgba(34,197,94,.0), 0 0 0 rgba(34,197,94,.0); }
  20%{ box-shadow: 0 0 0 6px rgba(34,197,94,.16), 0 0 36px rgba(34,197,94,.22); }
  100%{ box-shadow: 0 0 0 0 rgba(34,197,94,.0), 0 0 0 rgba(34,197,94,.0); }
}




#feed .post{
  position: relative;
  padding-bottom: 10px; /* ajuste se precisar */
}

#feed .post::after{
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: var(--post-sep-h);
  background: linear-gradient(90deg,
    #16a34a 0%,
    #16a34a 12%,
    #facc15 28%,
    #2563eb 42%,
    #ffffff 50%,
    #2563eb 58%,
    #facc15 72%,
    #16a34a 88%,
    #16a34a 100%
  );
  opacity: var(--post-sep-opacity);
}

.post:hover{ background: rgba(255,255,255,0.015); }

/* filho flex precisa poder encolher */
.post > div:last-child{ min-width:0; }

/* HEADER do post (1 lugar só, sem duplicar) */
.post-header{
  display:flex;
  align-items:center;
  gap:8px;
  flex-wrap:nowrap;
  min-width:0;
  margin-bottom:4px;
  position:relative;
}

/* se você usar wrappers (ph-left/ph-right), funciona também */
.post-header .ph-left{
  display:flex;
  align-items:center;
  gap:8px;
  min-width:0;
  flex:1 1 auto;
}
.post-header .ph-right{
  display:flex;
  align-items:center;
  gap:8px;
  flex:0 0 auto;
  white-space:nowrap;
}

.p-name{
  font-weight:800;
  color: var(--txt-primary);
  min-width:0;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  flex:0 1 auto;
}
.p-user{
  color: var(--txt-secondary);
  font-size:14px;
  min-width:0;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  flex:1 1 auto; /* é o que mais encolhe */
  opacity:.85;
}
.p-time{
  color: var(--txt-secondary);
  font-size:14px;
  margin-left:auto;
  flex:0 0 auto;
  white-space:nowrap;
  opacity:.75;
}

/* se ficar MUITO apertado, some com @ pra salvar a linha */
@media (max-width:360px){
  .post-header .p-user{ display:none; }
}

.post .p-content{
  max-width:100%;
  overflow-wrap:anywhere;
  word-break:break-word;
  white-space:pre-wrap; /* padrão */
}

.p-actions{
  display:flex;
  justify-content:space-between;
  max-width:420px;
  margin-top:12px;
  color: var(--txt-secondary);
}
.action{
  display:inline-flex;
  align-items:center;
  gap:6px;
  font-size:13px;
  background:transparent;
  border:none;
  color:inherit;
  cursor:pointer;
  padding:6px 8px;
  margin-left:-6px;
  border-radius:99px;
}
.action:hover{ background: rgba(255,255,255,0.04); }
.action svg{
  width:18px; height:18px;
  fill:transparent;
  stroke: currentColor;
  stroke-width:2px;
}
.action.liked{ color:#f7f6f8; }
.action.liked svg{ fill:#f7f6f8; stroke:#f7f6f8; }
.action.reposted{ color:#22c55e; }
.action.reposted svg{ stroke:#22c55e; }

.btn-delete{
  color:#98ff96;
  background:none;
  border:none;
  cursor:pointer;
  opacity:0.7;
  transition:.2s;
  margin-left:auto;
  padding:12px;
  margin-top:-10px;
  margin-right:-10px;
  position:relative;
  z-index:10;
  flex:0 0 auto;
  opacity: .55;
  transition: .05s;
}
.btn-delete:hover{ opacity:1; transform: scale(1.08); }
.btn-delete svg{ width:18px; height:18px; stroke: currentColor; stroke-width:2; fill:none; }

/* REPLIES shared (feed + perfil) */
.post .reply-form{
  display:none;
  margin-top:15px;
  border-top:1px solid var(--border);
  padding-top:15px;
}
.post .reply-form.active{ display:block; }

.post .reply-input-wrapper{
  display:flex;
  gap:10px;
  align-items:flex-start;
  min-width:0;
}
.post .reply-input-wrapper textarea{
  flex:1 1 auto;
  min-width:0;
  max-width:100%;
  border:1px solid #334155;
  background:#1e293b;
  border-radius:10px;
  padding:10px;
  color: var(--txt-primary);
  resize:none;
  outline:none;
  font-size:14px;
  min-height:42px;

  overflow-wrap:anywhere;
  word-break:break-word;
}
.post .reply-form button[type="submit"]{
  background: var(--brand-primary);
  color:#001018;
  border:none;
  padding:10px 14px;
  border-radius:10px;
  font-weight:900;
  cursor:pointer;
  white-space:nowrap;
}

.post .replies-container{
  display:none;
  background: rgba(30, 41, 59, 0.2);
  border-top:1px solid var(--border);
  padding:10px 16px 1px 16px;
  max-width:100%;
  overflow:hidden; /* sem scroll lateral */
}
.post .replies-container.active{ display:block; }

.post .reply-item{
  display:flex;
  gap:12px;
  padding-bottom:12px;
  margin-bottom:10px;
  border-bottom:1px dashed rgba(255,255,255,0.05);
  min-width:0;
  max-width:100%;
}
.post .reply-item:last-child{
  border-bottom:none;
  padding-bottom:0;
  margin-bottom:0;
}
.post .reply-content-wrapper{
  flex:1 1 auto;
  min-width:0;
  max-width:100%;
}
.post .reply-header{
  display:flex;
  gap:6px;
  align-items:baseline;
  margin-bottom:2px;
  flex-wrap:wrap;
  min-width:0;
}

/* se vier nome/handle gigante, não explode */
.post .reply-name,
.post .reply-user{
  min-width:0;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  max-width:55%;
}

.post .reply-name{ font-weight:900; font-size:13px; }
.post .reply-user,
.post .reply-time{ color: var(--txt-secondary); font-size:12px; }

.post .reply-text{
  font-size:14px;
  line-height:1.4;
  max-width:100%;
  overflow-wrap:anywhere;
  word-break:break-word;
  white-space:pre-wrap;
}

.post .no-replies{
  text-align:center;
  color: var(--txt-secondary);
  font-size:14px;
  padding:10px 0;
}
.post .no-replies.error{ color:#ef4444; }

.post .reply-like{
  background:none;
  border:none;
  display:inline-flex;
  align-items:center;
  gap:4px;
  padding:4px 8px;
  border-radius:999px;
  font-size:12px;
  color: var(--txt-secondary);
  cursor:pointer;
}
.post .reply-like svg{
  width:14px; height:14px;
  stroke: currentColor;
  fill: transparent;
  stroke-width:2;
}
.post .reply-like.liked{ color:#ef4444; }
.post .reply-like.liked svg{ fill:#ef4444; stroke:#ef4444; }

/* mobile nav por padrão off no desktop */
.mobile-nav{ display:none; }

/* =========================
   8) FEED (scoped)
   ========================= */
.page-feed .topbar{
  position:sticky;
  top:0;
  z-index:50;
  background: rgba(2, 6, 23, 0.95);
  backdrop-filter: blur(12px);
  border-bottom:1px solid var(--border);
}

.page-feed .tabs{
  display:flex;
  height: var(--header-height-desktop);
}

.tabs {
  display: flex;
  justify-content: space-around;
  border-bottom: 1px solid var(--border);
}

.tab {
  padding: 10px;
  background: none;
  border: none;
  color: var(--txt-secondary);
  font-weight: 500;
}

.tab.active {
  color: var(--brand-primary);
  border-bottom: 2px solid var(--brand-primary);
}

.notificacao-item {
  padding: 12px;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
}


.page-feed .tab{
  flex:1;
  display:flex;
  align-items:center;
  justify-content:center;
  font-weight:700;
  color: var(--txt-secondary);
  cursor:pointer;
  position:relative;
  font-size:15px;
  user-select:none;
  transition: color .2s ease;
}
.page-feed .tab:hover{ color:#cbd5e1; }

.page-feed .tab.active-for-you{
  background: -webkit-linear-gradient(45deg, var(--br-green), #34d399);
  -webkit-background-clip:text;
  -webkit-text-fill-color:transparent;
}
.page-feed .tab.active-following{
  background: -webkit-linear-gradient(45deg, var(--br-yellow), #fcd34d);
  -webkit-background-clip:text;
  -webkit-text-fill-color:transparent;
}
.page-feed .tab.active-for-you::after,
.page-feed .tab.active-following::after{
  content:"";
  position:absolute;
  bottom:3px;
  width:40px;
  height:6px;
  border-radius:4px 4px 0 0;
}
.page-feed .tab.active-for-you::after{
  background: var(--br-green);
  box-shadow:0 -2px 10px rgba(16, 185, 129, 0.4);
}
.page-feed .tab.active-following::after{
  background: var(--br-yellow);
  box-shadow:0 -2px 10px rgba(251, 191, 36, 0.4);
}

/* “cola” topbar no composer */
.page-feed .center{ gap:0 !important; }
.page-feed .topbar{ margin:0 !important; padding-bottom:0 !important; background:#081534;}

/* Composer */
.page-feed .composer{
  position:sticky;
  top: 38px;
  z-index:40;
  padding:16px;
  display:flex;
  gap:12px;
  background: rgba(2, 6, 23, 0.95);
  backdrop-filter: blur(10px);
  border-bottom:2px solid rgba(16, 185, 129, 0.9);
  box-shadow:0 1px 0 rgba(251, 191, 36, 0.3);
  background:#081534;
}
.page-feed .composer .input-area{ flex:1; }

.page-feed .composer textarea{
  font-family: Verdana;
  font-size:18px;
  line-height:1.5;
  margin-top:0;
  min-height:50px;
  max-height:220px;
  overflow:hidden;
}

.page-feed .composer-tools{
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-top:2px;
  border-top:1px solid rgba(255,255,255,0.05);
  padding:1px;
  gap:12px;
}
.page-feed .tools-icons{
  display:flex;
  align-items:center;
  gap:12px;
  color: var(--brand-primary);
  position:relative; /* ancora do emoji pop */
}
.page-feed #fileInput{ display:none; }

.page-feed .tool-icon{
  width:32px; height:32px;
  border-radius:999px;
  display:grid;
  place-items:center;
  cursor:pointer;
  user-select:none;
  background:transparent;
  border:0;
  padding:0;
  color:inherit;
  touch-action: manipulation;
}
.page-feed .tool-icon:hover{ background: rgba(255,255,255,0.04); }
.page-feed .tool-icon svg{ width:18px; height:18px; display:block; }

.page-feed .btn-send{
  background: var(--brand-primary);
  color: #001018;
  border:none;
  padding:3px 10px;
  border-radius: var(--radius-pill);
  font-weight:900;
  font-size:16px;
  cursor:pointer;
  display:flex;
  align-items:center;
  gap:2px;
  transition: all 0.2s ease;
}
.page-feed .btn-send:disabled{ opacity:0.5; cursor:not-allowed; transform:none; }

/* FEED: esconder topbar/composer no scroll (mobile) */
@media (max-width: 768px) {
  .page-feed main.center .topbar,
  .page-feed main.center .composer {
    transition: transform 0.25s ease, opacity 0.2s ease;
    will-change: transform, opacity;
  }

  .page-feed main.center .topbar.hide-on-scroll,
  .page-feed main.center .composer.hide-on-scroll {
    transform: translateY(-150%);
    opacity: 0;
    pointer-events: none;
  }
}

/* Contador */
.char-count{
  font-size:12px;
  font-weight:800;
  letter-spacing:.2px;
  color: rgba(148, 163, 184, .85);
  background: transparent;
  padding: 2px 6px;
  border-radius: 999px;
  user-select:none;
  white-space:nowrap;
}
.char-count.over{ color: rgba(239, 68, 68, .95); }

/* Texto do post (final do feed) */
.page-feed .post .p-content{
  font-size:16px;
  line-height:1.35;
  margin: 2px 0 6px;
  color:#e2e8f0;

  /* usa nl2br() no PHP */
  white-space: normal;

  overflow-wrap:anywhere;
  word-break:break-word;
}

/* Follow */
.follow-btn{
  margin-left:10px;
  padding:6px 10px;
  border-radius:999px;
  border:1px solid rgba(148,163,184,.25);
  background: rgba(255,255,255,0.03);
  color:#e2e8f0;
  font-size:12px;
  font-weight:800;
  cursor:pointer;
}
.follow-btn:hover{ background: rgba(255,255,255,0.06); }
.follow-btn.is-following{
  border-color: rgba(34,197,94,.35);
  color:#22c55e;
  background: rgba(34,197,94,.08);
}
.follow-btn:disabled{ opacity:.6; cursor:not-allowed; }

.page-feed .tab-badge.is-zero{
  -webkit-text-fill-color: rgba(148,163,184,.9);
  color: rgba(148,163,184,.9);
  
}

/* quando a aba estiver ativa, reforça */
.page-feed .tab.active-for-you .tab-badge,
.page-feed .tab.active-following .tab-badge{
  -webkit-text-fill-color: currentColor !important;
  color:#fcd34d !important;
}

.page-feed .tab.active-following .tab-text{
  background: -webkit-linear-gradient(45deg, var(--br-yellow), #fcd34d);
  -webkit-background-clip:text;
  -webkit-text-fill-color:transparent;
}

.page-feed .tab.active-for-you .tab-text{
  background: -webkit-linear-gradient(45deg, var(--br-green), #34d399);
  -webkit-background-clip:text;
  -webkit-text-fill-color:transparent;
}


/* Preview grid */
.page-feed .preview-wrap{ display:none; margin-top:10px; }
.page-feed .preview-top{
  display:flex;
  align-items:center;
  justify-content:space-between;
  color: var(--txt-secondary);
  font-size:13px;
  margin-bottom:8px;
}
.page-feed .preview-top b{ color: var(--txt-primary); }

.page-feed .preview-grid{
  display:grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap:8px;
}
.page-feed .prev-item{
  position:relative;
  border-radius:12px;
  overflow:hidden;
  border:1px solid rgba(255,255,255,0.12);
  aspect-ratio: 1 / 1;
  background: rgba(255,255,255,0.03);
}
.page-feed .prev-item img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}
.page-feed .prev-remove{
  position:absolute;
  top:6px; right:6px;
  width:26px; height:26px;
  border:none;
  border-radius:999px;
  background: rgba(0,0,0,0.65);
  color:#fff;
  cursor:pointer;
  font-weight:900;
  display:grid;
  place-items:center;
}
.page-feed .prev-remove:hover{ background: rgba(0,0,0,0.8); }

/* Carrossel do feed */
.page-feed .media{
  margin-top:10px;
  border-radius:12px;
  border:1px solid rgba(255,255,255,0.1);
  overflow:hidden;
  background: rgba(255,255,255,0.02);
  position:relative;
}
.page-feed .media-track{
  display:flex;
  overflow-x:auto;
  scroll-snap-type:x mandatory;
  scrollbar-width:none;
}
.page-feed .media-track::-webkit-scrollbar{ width:0; height:0; }
.page-feed .media-slide{ min-width:100%; scroll-snap-align:start; position:relative; }
.page-feed .media-slide img{
  width:100%;
  height: min(420px, 55vh);
  object-fit:cover;
  display:block;
}
.page-feed .media-nav{
  position:absolute;
  inset:auto 10px 10px 10px;
  display:flex;
  justify-content:space-between;
  align-items:center;
  pointer-events:none;
}
.page-feed .media-btns{ display:flex; gap:8px; pointer-events:auto; }
.page-feed .media-btn{
  width:34px; height:34px;
  border-radius:999px;
  border:1px solid rgba(255,255,255,0.18);
  background: rgba(2, 6, 23, 0.55);
  color:#fff;
  cursor:pointer;
  display:grid;
  place-items:center;
}
.page-feed .media-btn:hover{ background: rgba(2, 6, 23, 0.75); }
.page-feed .media-dots{ display:flex; gap:6px; pointer-events:auto; }
.page-feed .dot{
  width:7px; height:7px;
  border-radius:50%;
  background: rgba(255,255,255,0.35);
  border:none;
  cursor:pointer;
}

.page-feed .dot.active{ background: rgba(255,255,255,0.95); }

.media { overflow: hidden; }
.media-track {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.media-track::-webkit-scrollbar { display:none; }
.media-slide { flex: 0 0 100%; scroll-snap-align: start; }
.media-slide img { width:100%; display:block; }


/* Emoji pop (desktop abre pra baixo) */
.page-feed .emoji-pop{
  position:absolute;
  left:0;
  top: calc(100% + 10px);
  bottom:auto;

  width:310px;
  max-width: min(85vw, 360px);
  background: rgba(15, 23, 42, 0.98);
  border:1px solid rgba(148, 163, 184, 0.22);
  border-radius:14px;
  box-shadow:0 18px 40px rgba(0,0,0,.45);
  padding:10px;
  display:none;
  z-index:999;
}
.page-feed .emoji-pop.open{ display:block; }

.page-feed .emoji-head{
  display:flex;
  gap:8px;
  align-items:center;
  margin-bottom:10px;
}
.page-feed #emojiSearch{
  flex:1;
  background: rgba(255,255,255,0.06);
  border:1px solid rgba(255,255,255,0.10);
  color: var(--txt-primary);
  padding:10px;
  border-radius:10px;
  outline:none;
  font-size:16px;
}
.page-feed .emoji-close{
  width:36px; height:36px;
  border-radius:10px;
  border:1px solid rgba(255,255,255,0.10);
  background: rgba(255,255,255,0.06);
  color: var(--txt-primary);
  font-weight:900;
  cursor:pointer;
}
.page-feed .emoji-close:hover{ background: rgba(255,255,255,0.10); }

.page-feed .emoji-title{
  font-size:16px;
  color: var(--txt-secondary);
  margin: 4px 2px 8px;
}
.page-feed .emoji-grid{
  display:grid;
  grid-template-columns: repeat(5, 1fr);
  gap:1px;
}
.page-feed .emoji-item{
  width:100%;
  aspect-ratio: 1 / 1;
  border-radius:10px;
  border:1px solid transparent;
  background: rgba(255,255,255,0.03);
  cursor:pointer;
  display:grid;
  place-items:center;
  font-size:18px;
}
.page-feed .emoji-item:hover{
  background: rgba(255,255,255,0.08);
  border-color: rgba(6,182,212,0.25);
}

/* mobile: emoji vira bottom-sheet */
@media (max-width: 720px){
  .page-feed .emoji-pop{
    position:fixed;
    left:12px;
    right:12px;
    bottom:76px;
    top:auto;

    width:auto;
    max-width:none;
    z-index:999;
  }
}

/* Feed (mobile) header compacto */
@media (max-width: 560px){
  .page-feed .post{ padding:12px 12px; }
  .page-feed .p-content{
    margin: 6px 0 8px;
    line-height: 1.35;
  }
  .page-feed .p-actions{ margin-top:6px; }
}

/* =========================
   9) PERFIL (scoped)
   ========================= */
.page-profile .profile-header{ padding: 0 16px; margin-top: 10px; }

/* =========================
   PERFIL: Banner/Cover (CANÔNICO, sem duplicação)
   ========================= */

/* base */
.page-profile{
  --cover-h: clamp(96px, 26vw, 220px);
  --cover-mb: clamp(44px, 8vw, 58px);
  --cover-radius: var(--radius-lg);
}

.page-profile .cover-area{
  height: var(--cover-h);
  margin-bottom: var(--cover-mb);
  border-radius: var(--cover-radius);
  position: relative;
  overflow: visible;
  padding: 0;
}

/* touch devices (celular/tablet): cover “colado” nas bordas, sem raio */
@media (hover: none) and (pointer: coarse){
  .page-profile{ --cover-radius: 0; }
}



/* Perfil: banner container (camada do fundo) */
.page-profile .cover-media{
  position:absolute;
  inset:0;
  border-radius: var(--radius-lg);
  overflow:hidden;
  background: linear-gradient(to right, #1e293b, #0f172a);
  z-index:0;
}

.page-profile .cover-media::after{
  content:"";
  position:absolute;
  inset:0;
  background: linear-gradient(to bottom, rgba(2,6,23,.10), rgba(2,6,23,.65));
  z-index:2;
}

.page-profile .cover-img{
  position:absolute;       /* importante se seu container for tipo "cover-media" */
  inset:0;
  width:100%;
  height:100%;
  display:block;
  pointer-events:none;
  padding:0;
  z-index:1;
  
  object-fit: cover;       /* aqui sim rola recorte */
  /* NÃO fixe center aqui se o PHP vai mandar o foco */
  /* object-position: center; */
}




/* fundo “bonito” usando a própria imagem em blur */
.page-profile .cover-blur{
  position:absolute;
  inset:-24px;
  background-image: var(--banner);
  background-size: cover;      /* aqui pode ser cover, é só blur */
  background-position: center;
  filter: blur(18px) saturate(1.15);
  transform: scale(1.08);
  opacity:.45;
  z-index:0;
}

/* seu overlay continua valendo */
.page-profile .cover-media::after{
  content:"";
  position:absolute;
  inset:0;
  background: linear-gradient(to bottom, rgba(2,6,23,.10), rgba(2,6,23,.65));
  z-index:2;
}

.page-profile .big-avatar{
  width:100px; height:100px;
  border-radius:50%;
  border:4px solid var(--bg-body);
  position:absolute;
  bottom:-50px;
  left:20px;
  background:#334155;
  overflow:hidden;
  display:grid;
  place-items:center;
  font-size:40px;
  line-height:1;
  box-shadow:0 0 10px rgba(0,0,0,0.5);
  z-index:10;
}

  .page-profile .big-avatar{
    width:84px; height:84px;
    bottom:-34px;
    left:14px;
  }


.page-profile .big-avatar img{
  width:100%;
  height:100%;
  object-fit: cover !important;
  object-position: 50% 50%;
  display:block;
}


.page-profile .profile-actions{
  display:flex;
  justify-content:flex-end;
  align-items:center;
  gap:10px;
  padding-top:12px;
}
.page-profile .btn-edit,
.page-profile .btn-admin,
.page-profile .btn-danger{
  border-radius: var(--radius-pill);
  font-weight:900;
  cursor:pointer;
  transition:.2s;
}
.page-profile .btn-edit{
  border:1px solid var(--border);
  background:transparent;
  color: var(--txt-primary);
  padding:6px 16px;
  font-weight:800;
}
.page-profile .btn-edit:hover{ background: var(--bg-hover); }

.page-profile .btn-admin{
  border:1px solid rgba(6,182,212,0.35);
  background: rgba(6,182,212,0.10);
  color:#a5f3fc;
  padding:6px 14px;
}
.page-profile .btn-admin:hover{ background: rgba(6,182,212,0.16); }

.page-profile .btn-danger{
  border:1px solid rgba(239,68,68,.35);
  background: rgba(239,68,68,.08);
  color:#fecaca;
  padding:6px 14px;
}
.page-profile .btn-danger:hover{ background: rgba(239,68,68,.16); }

.page-profile .profile-info{ padding: 0 4px; margin-top: 10px; }
.page-profile .user-name{ font-size:20px; font-weight:900; }
.page-profile .user-handle{ color: var(--txt-secondary); font-size:16px; }
.page-profile .user-bio{ margin-top:12px; font-size:16px; line-height:1.5; color:#e2e8f0; }

.page-profile .user-meta{
  display:flex;
  gap:16px;
  margin-top:12px;
  color: var(--txt-secondary);
  font-size:16px;
  align-items:center;
  flex-wrap:wrap;
}
.page-profile .user-meta svg{ width:16px; height:16px; margin-right:4px; }

.page-profile .follow-data{
  display:flex;
  gap:16px;
  margin-top:12px;
  font-size:16px;
}
.page-profile .follow-data b{ color: var(--txt-primary); }
.page-profile .follow-data span{ color: var(--txt-secondary); }

.page-profile .profile-tabs{
  display:flex;
  border-bottom:1px solid var(--border);
  position:sticky;
  top:-2px;
  background: rgba(2,6,23,.9);
  backdrop-filter: blur(10px);
  z-index:20;
  
}
.page-profile .p-tab{
  flex:1;
  text-align:center;
  padding:10px 2px;
  font-weight:900;
  color: var(--txt-secondary);
  cursor:pointer;
  position:relative;
  transition:.2s;
  user-select:none;
}
.page-profile .p-tab:hover{ background: rgba(255,255,255,0.03); }
.page-profile .p-tab.active{ color: var(--txt-primary); }
.page-profile .p-tab.active::after{
  content:"";
  position:absolute;
  bottom:0;
  left:50%;
  transform: translateX(-50%);
  width:40px;
  height:4px;
  background: var(--brand-primary);
  border-radius:4px 4px 0 0;
}

.page-profile .tab-panel{ display:none; padding:15px;}
.page-profile .tab-panel.active{ display:block; }

.page-profile .media-grid{
  display:grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap:6px;
  padding:16px;
}
.page-profile .media-grid a{
  display:block;
  border-radius:12px;
  overflow:hidden;
  border:1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.02);
  aspect-ratio: 1 / 1;
}
.page-profile .media-grid img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}

/* Badge na aba do Perfil (ex: Anúncios) */
.profile-tabs .tab-badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;

  margin-left: 2px;

  min-width: 18px;
  height: 18px;
  padding: 0 6px;

  border-radius: 999px;
  font-size: 11px;
  line-height: 18px;
  font-weight: 900;

  pointer-events: none;

  /* segue o mesmo "DNA" do seu badge verde */
  /*background: rgba(34,197,94,.22);
  /*color: rgba(209,250,229,.95);*/
  /*border: 1px solid rgba(34,197,94,.35);*/
  
  background: rgba(239,68,68,.20);
  color: rgba(254,226,226,.95);
  border: 1px solid rgba(239,68,68,.35);
}


/* divisor no perfil (posts do perfil) */
body.page-profile .feed .post{
  border-bottom: .65px solid rgba(255,255,255,.06); /* discreto */
}

body.page-profile .feed .post:last-child{ border-bottom: 0; }

.flash { outline:2px solid rgba(255,255,255,.35); box-shadow:0 0 0 6px rgba(255,255,255,.08); }


/* FEED: linha gradiente “BR raiz” fina */
body.page-feed:not(.page-profile) #feed .post{
  position: relative;
}

body.page-feed:not(.page-profile) #feed .post::after{
  content:"";
  position:absolute;
  left:0; right:0; bottom:0;
  height:1px;
  background: linear-gradient(90deg,
    #16a34a 0%,
    #16a34a 12%,
    #facc15 28%,
    #2563eb 42%,
    #ffffff 50%,
    #2563eb 58%,
    #facc15 72%,
    #16a34a 88%,
    #16a34a 100%
  );
  opacity:.65;
  transform: scaleY(.65);        /* “0.65px” na prática */
  transform-origin: bottom;
  pointer-events:none;
}

body.page-feed:not(.page-profile) #feed .post:last-child::after{ display:none; }

/* fallback se algum device “engrossar” */
@supports not (transform: scaleY(.65)){
  body.page-feed:not(.page-profile) #feed .post{ border-bottom:1px solid rgba(255,255,255,.08); }
}

.profile-cover{
  aspect-ratio: 3 / 1;
  width: 100%;
  min-height: 140px;
  max-height: 240px;
  border-radius: 18px;
  overflow: hidden;
  position: relative;
  background: linear-gradient(90deg,#1e293b,#0f172a);
}

.profile-cover-img{
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.profile-avatar{
  width: 96px;
  height: 96px;
  border-radius: 50%;
  overflow: hidden;
}

.profile-avatar-img{
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}


/* Por padrão, muita gente usa cover (corta). Mas pra banner com texto, usa contain (não corta). */
.page-profile .cover-media.fit-contain .cover-img{
  object-fit: contain !important;  /* não corta letra */
}

/* Se quiser manter “capa estilo Facebook” (corta pra preencher), use fit-cover */
.page-profile .cover-media.fit-cover .cover-img{
  object-fit: cover !important;
}



/* =========================
   10) VITRINE / ANÚNCIOS (scoped e SEM DUPLICAR)
   ========================= */

/* Vitrine não tem left/right: vira 1 coluna */
body.page-vitrine .app{
  grid-template-columns: minmax(0, var(--center-width));
  gap:0;
  justify-content:center;
}
body.page-vitrine .left,
body.page-vitrine .right{ display:none !important; }

body.page-vitrine .center{
  width:100%;
  max-width: var(--center-width);
  margin:0 auto;
  overflow-y:auto;
  overflow-x:hidden;
  padding-bottom:110px;
}

/* Topbar */
.page-vitrine .topbar{
  position: sticky;
  top: 0;
  z-index: 50;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(2, 6, 23, .92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.page-vitrine .topbar a.back{
  color: var(--brand-primary);
  font-weight: 900;
  font-size: 16px;
}
.page-vitrine .title{
  font-size: 16px;
  font-weight: 900;
}

/* Card do anúncio (compat: ad-card e ad-card2) */
.page-vitrine .ad-card,
.page-vitrine .ad-card2{
  padding:16px;
  border-bottom: 1px solid rgba(16, 185, 129, 0.15);
  box-shadow: 0 1px 0 rgba(251, 191, 36, 0.12);

  /* trava anti-“sumir” */
  display:block;
  opacity:1;
  visibility:visible;
}
.page-vitrine .ad-header{
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  margin-bottom: 8px;
}
.page-vitrine .ad-username{
  font-weight: 900;
  font-size: 16px;
  line-height: 1.15;
}
.page-vitrine .ad-handle{
  color: var(--txt-secondary);
  font-size: 16px;
}

.page-vitrine .ad-text{
  font-size: 16px;
  line-height: 1.5;
  margin: 10px 0 10px;
  color:#e2e8f0;

  /* você usa nl2br() no PHP */
  white-space: normal;

  overflow-wrap:anywhere;
  word-break:break-word;

  display:block;
  opacity:1;
  visibility:visible;
}

.page-vitrine .cls-details{
  display:flex;
  flex-wrap:wrap;
  gap: 10px 14px;
  align-items: center;
  color: var(--txt-secondary);
  font-size: 16px;
  margin-bottom: 12px;
}
.page-vitrine .cls-details b{
  color:#4ade80;
  font-weight:900;
}

/* Carrossel Vitrine (vtr-*) */
.page-vitrine .vtr-media{
  margin-top: 10px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.10);
  overflow: hidden;
  background: rgba(255,255,255,0.02);
  position: relative;
}

.page-vitrine .vtr-track{
  display: flex;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
}
.page-vitrine .vtr-track::-webkit-scrollbar{ width:0; height:0; }

.page-vitrine .vtr-slide{
  min-width: 100%;
  scroll-snap-align: start;
  position: relative;
}
.page-vitrine .vtr-slide img{
  width: 100%;
  height: min(520px, 62vh);
  object-fit: cover;
  display: block;
  cursor: zoom-in;
  user-select:none;
}

/* setas + bolinhas */
.page-vitrine .vtr-nav{
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  pointer-events: none;
  gap: 10px;
}
.page-vitrine .vtr-btns{
  display:flex;
  gap:8px;
  pointer-events:auto;
}
.page-vitrine .vtr-btn{
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.18);
  background: rgba(2, 6, 23, 0.55);
  color:#fff;
  cursor:pointer;
  display:grid;
  place-items:center;
}
.page-vitrine .vtr-btn:hover{ background: rgba(2, 6, 23, 0.75); }
.page-vitrine .vtr-btn svg{
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.5;
}
.page-vitrine .vtr-dots{
  display:flex;
  gap:6px;
  pointer-events:auto;
}
.page-vitrine .vtr-dot{
  width:7px;
  height:7px;
  border-radius:50%;
  border:none;
  background: rgba(255,255,255,0.35);
  cursor:pointer;
}
.page-vitrine .vtr-dot.active{ background: rgba(255,255,255,0.95); }

/* ações (reaproveita padrão) */
.page-vitrine .ad-actions{
  display:flex;
  justify-content: space-between;
  width:100%;
  margin-top:12px;
  color: var(--txt-secondary);
}
.page-vitrine .ad-actions .action{ margin-left:-6px; }

/* Preview (modal) */
#imgPreview{
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.88);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}
#imgPreview img{
  max-width: 92%;
  max-height: 92%;
  border-radius: 12px;
}

.page-anuncios .th-comment-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
}

.page-anuncios .ad-ch-left{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  align-items:baseline;
  min-width:0;
}

.page-anuncios .th-reply-btn{
  padding:6px 10px;
  border:1px solid var(--border);
  background:rgba(255,255,255,.03);
  color:var(--txt-primary);
  border-radius:999px;
  font-weight:900;
  font-size:12px;
  cursor:pointer;
  white-space:nowrap;
}

.page-anuncios .th-reply-btn:active{
  transform: translateY(1px);
}

/* iOS Safari: evitar zoom em inputs < 16px */
.page-anuncios .th-comments textarea,
.page-anuncios .th-inline-form textarea{
  font-size:16px;
  line-height:1.35;
}

/* ===== ANÚNCIOS: impedir texto de vazar (palavra sem espaço) ===== */
.page-anuncios .th-comments,
.page-anuncios .th-comments *{
  max-width: 100%;
}

/* o corpo do comentário e respostas */
.page-anuncios .th-comment-body,
.page-anuncios .th-comment,
.page-anuncios .th-reply{
  overflow-wrap: anywhere;   /* melhor arma */
  word-break: break-word;    /* fallback */
}

/* Perfil: separador da aba "Comentou" */
.mini-sep{
  border: 0;
  height: 1px;
  background: rgba(255,255,255,.08);
  margin: 12px 6px;
}


/* header do comentário (nome/@user/data + botão) */
.page-anuncios .th-comment-head{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

/* permite o lado esquerdo ENCOLHER e quebrar linha */
.page-anuncios .ad-ch-left{
  min-width: 0;              /* ESSENCIAL em flex */
  overflow-wrap: anywhere;
  word-break: break-word;
}

/* evita o botão esmagar o layout */
.page-anuncios .th-reply-btn{
  flex: 0 0 auto;
  white-space: nowrap;
}

/* (opcional) se ainda existir scroll horizontal por algum motivo */
.page-anuncios{
  overflow-x: hidden;
}

.page-anuncios .ad-text2{
  overflow-wrap:anywhere;
  word-break:break-word;
}

.page-anuncios .th-comments textarea,
.page-anuncios .th-inline-form textarea{
  font-size: 16px;
  line-height: 1.35;
}



/* =========================
   11) RESPONSIVO
   ========================= */
@media (max-width: 1080px){
  .app{ grid-template-columns: 80px auto 300px; }
  .nav a span{ display:none; }
  .nav a{ justify-content:center; }
}

@media (max-width: 720px){
  .app{ display:block; padding:0; }
  .left, .right{ display:none; }
  .center{ border:none; padding-bottom:92px; }

  /* Feed sticky */
  .page-feed .topbar{ height:50px; }
  .page-feed .tabs{ height:47px; }
  .page-feed .composer .avatar{ display:none; }

  /* Vitrine mobile */
  body.page-vitrine .center{ padding-bottom:92px; }
  .page-vitrine .vtr-slide img{ height: min(420px, 50vh); }
  .page-vitrine .vtr-btns{ display:none; }
}

.page-ad .ad-single-media{
  display:grid;
  gap:10px;
}

.page-ad .ad-single-img{
  width:100%;
  height:auto;
  display:block;
  border-radius:14px;
  max-height:520px;
  object-fit:cover;
}



/* =========================
   12) MOBILE NAV (shared)
   ========================= */
@media (max-width: 720px){
  .mobile-nav{
    position:fixed;
    bottom:0;
    left:0;
    right:0;
    display:flex;
    justify-content:space-around;
    align-items:center;
    gap:5px;

    background: rgba(2,6,23,0.95);
    backdrop-filter: blur(10px);
    border-top:1px solid var(--border);
    
    padding:20px 2px;
    padding-bottom: calc(10px + env(safe-area-inset-bottom));
    z-index:100;
  }

  .mobile-nav a{
    position:relative;              /* 👈 pra bolinha posicionar */
    width:44px;
    height:44px;
    display:grid;
    place-items:center;
    border-radius:14px;
    color: var(--txt-secondary);
    user-select:none;
    -webkit-tap-highlight-color: transparent;
    transition: transform .05s ease;
  }
  .mobile-nav a:active{ transform: scale(0.98); }

  .mobile-nav svg{
    width:26px;
    height:26px;
    color: var(--txt-secondary);
  }
  .mobile-nav a.active svg{ color: var(--brand-primary); }

  .mobile-nav .nav-me-avatar{
    width:30px;
    height:30px;
    border-radius:999px;
    display:grid;
    place-items:center;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.14);
    position:relative;
    overflow: visible;
  }

  .mobile-nav .nav-me-avatar .nav-avatar{
    width:100%;
    height:100%;
    object-fit:cover;
    display:block;
    border-radius:999px;
    overflow:hidden;
  }

  .mobile-nav .nav-me-avatar .nav-fallback{
    font-size:16px;
    line-height:1;
    transform: translateY(1px);
  }

  .mobile-nav a.nav-me.active .nav-me-avatar::after{
    content:"";
    position:absolute;
    inset:-3px;
    border-radius:999px;
    border:2px solid rgba(6,182,212,.95);
    box-shadow:
      0 0 0 3px rgba(6,182,212,.22),
      0 0 18px rgba(6,182,212,.20);
    pointer-events:none;
  }
}


    
    /*********************************************************/
    
    
    /* ===== Mobile nav badge (Perfil / Ads) ===== */
    .mobile-nav .nav-me-avatar{
      position: relative; /* âncora do badge */
      display: inline-flex;
      align-items: center;
      justify-content: center;
    }
    
    .mobile-nav .nav-badge.nav-badge--me{
      position: absolute;
      top: -6px;
      right: -10px;
      min-width: 18px;
      height: 18px;
      padding: 0 5px;
    
      display: inline-flex;
      align-items: center;
      justify-content: center;
    
      border-radius: 999px;
      font-size: 11px;
      font-weight: 900;
      line-height: 1;
    
      color: #fcd34d;
      background: #008000;           /* vermelho padrão badge */
      border: 1px solid var(--bg, #020617); /* aro pra não “sumir” no avatar */
      box-shadow: 0 6px 14px rgba(0,0,0,.35);
    
      pointer-events: none;
      z-index: 5;
      overflow: visible !important;
    }

    
    
    
    /*********************************************************/
    
    @media (max-width: 720px){
  .mobile-search-bar{
    position: fixed;
    left: 0;
    right: 0;
    bottom: calc(60px + env(safe-area-inset-bottom)); /* em cima da nav */
    padding: 1px 5px;
    background: rgba(8, 21, 52, 0.98);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    z-index: 101;

    transform: translateY(100%);
    opacity: 0;
    pointer-events: none;
    transition: transform .18s ease, opacity .18s ease;
  }

  .mobile-search-bar.open{
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .mobile-search-bar form{
    display: flex;
    align-items: center;
    gap: 8px;
  }

  .mobile-search-input{
    flex: 1;
    border-radius: 999px;
    border: 1px solid rgba(148,163,184,.45);
    background: rgba(15,23,42,0.95);
    color: var(--txt-primary);
    padding: 8px 14px;
    font-size: 16px;
    outline: none;
  }

  .mobile-search-input::placeholder{
    color: var(--txt-secondary);
  }

  .mobile-search-close{
    border-radius: 999px;
    border: none;
    padding: 7px 10px;
    background: transparent;
    color: var(--brand-primary);
    font-weight: 700;
    font-size: 16px;
    cursor: pointer;
  }
}


@media (max-width: 720px){
  .composer .emoji-pop{
  position:absolute;
  left:0;
  top: calc(100% + 10px);  /* <- abre pra baixo */
  bottom:auto;

  width:310px;
  max-width: min(85vw, 360px);
  background: rgba(15, 23, 42, 0.98);
  border:1px solid rgba(148, 163, 184, 0.22);
  border-radius:14px;
  box-shadow:0 18px 40px rgba(0,0,0,.45);
  padding:10px;
  display:none;
  z-index:999;
  }
}
@media (max-width:720px){
  body.page-feed .composer{ top:40px; }
}

/* Divisor BR só no PERFIL */
.page-profile .feed .post{
  border-bottom: 0 !important;
  position: relative;
}

/* Perfil: destaca o post focado vindo do "Ver post" */
.post.post-focus{
  outline: 2px solid rgba(34,197,94,.55);
  box-shadow: 0 0 0 6px rgba(34,197,94,.12);
  border-radius: 16px;
}


.hashtag{
  color: var(--brand, #22c55e);
  text-decoration: none;
  font-weight: 700;
}
.hashtag:hover{ text-decoration: underline; }

.p-content .hashtag{
  color: var(--brand, #22c55e);
  text-decoration: none;
  font-weight: 800;
}
.p-content .hashtag:hover{
  text-decoration: underline;
}

.p-content .hashtag,
.p-content .mention{
  font-weight: 800;
  text-decoration: none;
}

.p-content .hashtag{
  color: var(--brand, #22c55e);
}

.page-profile .post { scroll-margin-top: 90px; }

.p-content .mention{
  color: #60a5fa;
}

.p-content .hashtag:hover,
.p-content .mention:hover{
  text-decoration: underline;
}

.page-profile .feed .post::after{
  content:"";
  position:absolute;
  left:0;
  right:0;
  bottom:0;
  height:.65px;               /* sim, aceita quebrado */
  opacity:.95;
  background: linear-gradient(90deg,
    #10b981 0%,
    #10b981 12%,
    #fbbf24 26%,
    #2563eb 42%,
    #ffffff 50%,
    #2563eb 58%,
    #fbbf24 74%,
    #10b981 88%,
    #10b981 100%
  );
  pointer-events:none;
}

/* animação suave */
#tabs, .composer{
  transition: max-height .22s ease, opacity .18s ease, transform .22s ease, margin .22s ease, padding .22s ease;
  will-change: max-height, opacity, transform;
}

/* quando compacta */
body.feed-compact #tabs,
body.feed-compact .composer{
  max-height:0 !important;
  opacity:0;
  transform: translateY(-8px);
  overflow:hidden;
  pointer-events:none;
  margin:0 !important;
  padding-top:0 !important;
  padding-bottom:0 !important;
}

/* botão flutuante */
.quick-compose{
  position: fixed;
  right: 14px;
  bottom: calc(76px + env(safe-area-inset-bottom)); /* sobe acima da mobile nav */
  z-index: 999;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(8,21,52,.92);
  color: #fff;
  font-weight: 900;
  display:flex;
  align-items:center;
  justify-content:center;
  box-shadow: 0 10px 30px rgba(0,0,0,.35);
  opacity:0;
  transform: scale(.92);
  pointer-events:none;
  transition: opacity .18s ease, transform .18s ease;
}

.quick-compose.show{
  opacity:1;
  transform: scale(1);
  pointer-events:auto;
}

.side-nav .nav-item.is-active {
  background: rgba(255,255,255,0.06);
  font-weight: 700;
  border-radius: 999px;
}

/* Badge do sininho no menu esquerdo (desktop) */
.left .nav a{
  position: relative;
}

.left .nav a .nav-badge{
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  min-width: 18px;
  height: 18px;
  padding: 0 6px;
  border-radius: 999px;
  font-size: 12px;
  line-height: 18px;
  font-weight: 800;
  letter-spacing: .2px;
  background: var(--danger, #24b30e);
  color: #fff;
  box-shadow: 0 8px 20px rgba(0,0,0,.25);
}


.new-posts-bar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  justify-content: center;
  margin-bottom: 8px;
}

.new-posts-bar button {
  background: #22c55e;
  color: #02101f;
  border: none;
  padding: 6px 16px;
  border-radius: 999px;
  font-weight: 600;
  cursor: pointer;
}

.no-scroll { overflow: hidden; }

.page-anuncios .th-comments-list{ list-style:none; padding:0; margin:10px 0 0; }
.page-anuncios .th-comment, .page-anuncios .th-reply{ padding:10px 0; border-top:1px solid var(--line); }
.page-anuncios .th-comment-head{ display:flex; align-items:flex-start; justify-content:space-between; gap:10px; }
.page-anuncios .ad-ch-left{ display:flex; flex-wrap:wrap; gap:8px; align-items:baseline; min-width:0; }
.page-anuncios .th-replies{ list-style:none; margin:10px 0 0 14px; padding:0 0 0 10px; border-left:2px solid var(--line); }
.page-anuncios .th-inline-slot{ margin-top:10px; }
.page-anuncios .ad-inline-reply textarea{ width:100%; }
.page-anuncios .ad-inline-actions{ display:flex; gap:8px; margin-top:8px; justify-content:flex-end; }
.page-anuncios .th-reply-btn{
  padding:6px 10px; border:1px solid var(--border);
  background:rgba(255,255,255,.03); color:var(--txt-primary);
  border-radius:999px; font-weight:900; font-size:12px; cursor:pointer; white-space:nowrap;
}


/* =========================================================
   Poostaki — Mobile Nav + Search Bar (mobile) FIX FINAL
   - A e BUTTON iguais
   - Lupa acende por:
     1) .active
     2) .is-open
     3) aria-pressed="true"
     4) (BOMBA ATÔMICA) barra .open => acende via :has()
   ========================================================= */



/* -------- Reset A/BUTTON -------- */
.mobile-nav a,
.mobile-nav button{
  appearance: none;
  -webkit-appearance: none;
  background: transparent;
  border: 0;
  padding: 0;
  margin: 0;
  color: inherit;
  text-decoration: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

/* -------- Nav container -------- */
.mobile-nav{
  position: fixed;
  left: 0; right: 0; bottom: 0;

  padding-bottom: env(safe-area-inset-bottom);

  display: flex;
  align-items: center;
  justify-content: space-around;

  background: var(--mnav-bg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);

  border-top: 1px solid var(--mnav-border);
  z-index: 9999;
}

/* -------- Itens -------- */
.mobile-nav .nav-item,
.mobile-nav > a,
.mobile-nav > button{
  width: 44px;
  height: 44px;
  border-radius: 12px;

  display: grid;
  place-items: center;

  color: var(--mnav-icon);
  transition: background .15s ease, color .15s ease, transform .12s ease;
}

.mobile-nav svg{
  width: 22px;
  height: 22px;
}

/* clique */
.mobile-nav .nav-item:active,
.mobile-nav > a:active,
.mobile-nav > button:active{
  transform: translateY(1px);
}

/* foco */
.mobile-nav .nav-item:focus-visible,
.mobile-nav > a:focus-visible,
.mobile-nav > button:focus-visible{
  outline: 2px solid var(--mnav-focus);
  outline-offset: 2px;
}

/* -------- ACTIVE normal (se vier classe/aria) -------- */
.mobile-nav .nav-item.active,
.mobile-nav > a.active,
.mobile-nav > button.active,
.mobile-nav .nav-search.is-open,
.mobile-nav .nav-search[aria-pressed="true"]{
  color: var(--mnav-icon-active) !important;
  background: var(--mnav-active-bg) !important;
}

/* glow discreto na lupa quando ativa */
.mobile-nav .nav-search.is-open,
.mobile-nav .nav-search.active,
.mobile-nav .nav-search[aria-pressed="true"]{
  box-shadow: 0 0 0 1px rgba(56,189,248,.22), 0 0 14px rgba(56,189,248,.14);
}

/* -------- BÔNUS: ACENDE A LUPA SÓ PORQUE A BARRA ABRIU --------
   Estrutura do teu HTML:
   <nav class="mobile-nav">...</nav>
   <div class="mobile-search-bar open">...</div>
*/
@supports selector(nav:has(+ .mobile-search-bar.open)){
  nav.mobile-nav:has(+ .mobile-search-bar.open) .nav-search{
    color: var(--mnav-icon-active) !important;
    background: var(--mnav-active-bg) !important;
    box-shadow: 0 0 0 1px rgba(56,189,248,.22), 0 0 14px rgba(56,189,248,.14);
  }
}

/* =========================================================
   Search bar
   ========================================================= */
.mobile-search-bar{
  position: fixed;
  left: 10px;
  right: 10px;
  bottom: calc(var(--mnav-h) + env(safe-area-inset-bottom) + 10px);
  z-index: 10000;

  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: opacity .18s ease, transform .18s ease;
}

.mobile-search-bar.open{
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.mobile-search-bar form{
  background: var(--msearch-bg);
  border: 1px solid var(--msearch-border);
  border-radius: 14px;
  padding: 10px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.mobile-search-input{
  width: 100%;
  height: 40px;
  border-radius: 10px;
  border: 1px solid var(--minput-border);
  background: var(--minput-bg);
  color: var(--minput-txt);
  outline: none;
  padding: 0 12px;
}

.mobile-search-input::placeholder{
  color: var(--minput-ph);
}

.mobile-search-input:focus{
  border-color: rgba(56,189,248,.45);
  box-shadow: 0 0 0 3px rgba(56,189,248,.18);
}

.mobile-nav .nav-search.is-open,
.mobile-nav .nav-search.active,
.mobile-nav .nav-search[aria-pressed="true"]{
  color:#38bdf8;
  background:rgba(56,189,248,.12);
}

.mobile-nav.is-search-open .nav-search,
.mobile-nav .nav-search[aria-pressed="true"]{
  color:#38bdf8 !important;
  background:rgba(56,189,248,.12) !important;
  box-shadow: 0 0 0 1px rgba(56,189,248,.22), 0 0 14px rgba(56,189,248,.14);
}

/* =========================
   MOBILE NAV: só aparece no mobile
   ========================= */

/* DESKTOP: some tudo */
.mobile-nav,
.mobile-search-bar{
  display: none !important;
}

/* MOBILE: aparece (ajuste o breakpoint se quiser) */
@media (max-width: 900px){
  .mobile-nav{
    display: flex !important;
  }
  .mobile-search-bar{
    display: block !important;
  }

  /* Se você usa padding/margem pra não cobrir conteúdo, faz aqui */
  body{
    padding-bottom: calc(var(--mnav-h, 56px) + env(safe-area-inset-bottom));
  }
}

/* EXTRA: se quiser ser ainda mais “inteligente” (somente touch) */

@media (hover: none) and (pointer: coarse){
  .mobile-nav{ display:flex !important; }
  .mobile-search-bar{ display:block !important; }
}

/* =========================
   QUICK USERS (limpo)
   ========================= */

.quick-users{
  display:flex;
  gap:10px;
  align-items:center;
  padding:10px 12px;
  border-bottom: 1px solid rgba(148,163,184,.12);
  background:#081534;
  backdrop-filter: blur(10px);
}

.quick-top{
  width:44px;
  height:44px;
  border-radius:14px;
  display:grid;
  place-items:center;
  background:#003366;
  color:var(--mnav-icon-active, #081534);
  text-decoration:none;
  flex:0 0 auto;
}

.quick-scroll{
  display:flex;
  gap:10px;
  overflow-x:auto;
  -webkit-overflow-scrolling:touch;
  scrollbar-width:none;
  flex:1 1 auto;
  padding-bottom:14px; /* espaço pro @handle embaixo não cortar */
}
.quick-scroll::-webkit-scrollbar{ display:none; }

.quick-user{
  width:50px;
  height:50px;
  border-radius:50%;
  display:grid;
  place-items:center;
  background:rgba(15,23,42,.55);
  border:3px solid green;
  position:relative;
  flex:0 0 auto;

  overflow:visible; /* precisa pro @handle e badge aparecerem fora */
  text-decoration:none;
}

.quick-user img{
  width:45px;
  height:45px;
  border-radius:50%;
  object-fit:cover;
  display:block;
}

/* fallback (👤 / 🦗) */
.quick-user .avatar-fallback{
  font-size:24px;
  line-height:1;
}

/* Badge com @handle (embaixo) */
.quick-user[data-handle]::after{
  content: attr(data-handle);
  position:absolute;
  left:50%;
  bottom:-10px;
  transform:translateX(-50%);
  font-size:10px;
  line-height:1;
  padding:4px 7px;
  border-radius:999px;
  white-space:nowrap;
  max-width:70px; /* aumentei um pouco, 50 tava apertado */
  overflow:hidden;
  text-overflow:ellipsis;

  background:rgba(0,0,0,.55);
  border:1px solid rgba(255,255,255,.10);
  color:rgba(255,255,255,.92);
  backdrop-filter:blur(6px);
  pointer-events:none;
  box-shadow:0 6px 16px rgba(0,0,0,.25);
}

/* “tapa” no hover/focus */
.quick-user:hover::after,
.quick-user:focus-visible::after{
  background:rgba(0,0,0,.70);
  border-color:rgba(34,211,238,.35);
}

/* badge da bolinha (ex: 0 no grilo) */
.quick-badge{
  position:absolute;
  right:-6px;
  bottom:-6px;
  font-size:20px;
  line-height:1;
  padding:3px 6px;
  border-radius:999px;
  border:1px solid rgba(255,255,255,.16);
  background:rgba(2,6,23,.9);
  color:#fff;
  backdrop-filter:blur(6px);
}

.quick-user.is-empty .avatar-fallback{ filter:grayscale(.15); opacity:.9; }

/* esconder sugestões quando já segue */
.has-following .quick-user[data-kind="suggested"],
.quick-users.has-following .quick-user[data-kind="system"]{
  display:none;
}


/*****************************************
        MAIS USUARIOS PARA SEGUIR
******************************************/

.discover-modal[hidden]{ display:none; }
.discover-modal{
  position:fixed; inset:0; background:rgba(0,0,0,.45);
  display:flex; align-items:center; justify-content:center; z-index:9999;
}
.discover-card{
  width:min(520px, 92vw); max-height:80vh; overflow:auto;
  background:rgba(10,18,26,.96); border:1px solid rgba(255,255,255,.08);
  border-radius:16px; padding:12px;
}
.discover-head{ display:flex; justify-content:space-between; align-items:center; gap:10px; }
.discover-head .title{ font-weight:700; }
.discover-head .x{ font-size:22px; background:transparent; border:0; color:inherit; cursor:pointer; }

.discover-search{ width:100%; margin:10px 0; padding:10px 12px; border-radius:12px; font-size: 16px;
  border:1px solid rgba(255,255,255,.08); background:rgba(255,255,255,.06); color:inherit;
}

#discoverList { min-height: 220px; }
.discover-loading { padding: 14px; opacity: .75; }


.user-row{
  display:flex; gap:10px; padding:10px; border-radius:14px;
  border:1px solid rgba(255,255,255,.06); background:rgba(255,255,255,.03);
  margin-bottom:8px;
}
.user-row .av{ width:40px; height:40px; border-radius:50%; overflow:hidden; flex:0 0 40px; }
.user-row .av img{ width:100%; height:100%; object-fit:cover; display:block; }
.user-row .meta{ flex:1; min-width:0; }
.user-row .meta .line1{ display:flex; gap:8px; align-items:center; flex-wrap:wrap; }
.badge{ font-size:12px; padding:2px 8px; border-radius:999px; border:1px solid rgba(255,255,255,.12); opacity:.95; }
.badge.ok{ border-color: rgba(34,197,94,.35); color:#22c55e; background: rgba(34,197,94,.12); }
.user-row .bio{ opacity:.85; font-size:13px; margin-top:4px; }
.user-row .actions{ display:flex; align-items:center; }
.user-row .btn-follow{ padding:8px 10px; border-radius:12px; cursor:pointer; border:1px solid rgba(34,197,94,.35); background:rgba(34,197,94,.12); color:#22c55e; }
.user-row .btn-follow[disabled]{ opacity:.6; cursor:not-allowed; }

.btn-discover{
  flex:0 0 auto;
  height:34px;
  padding:0 10px;
  border-radius:999px;
  border:1px solid rgba(34,197,94,.35);
  background:rgba(34,197,94,.12);
  color:#22c55e;
  cursor:pointer;
  font-weight:600;
}
.btn-discover:hover{ filter:brightness(1.06); }



/****************FIM DO USUARIO A SEGUIR ******************************************/


.tab-badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  vertical-align:middle;
  transform:translateY(-1px);
  white-space:nowrap;

  min-width:18px;
  height:18px;
  padding:0 6px;
  margin-left:6px;

  border-radius:999px;
  font-size:12px;
  line-height:1;

  border:1px solid rgba(34,197,94,.35);

  /* FIX: não deixa o gradiente do pai “matar” o texto do badge */
  -webkit-text-fill-color: currentColor;
}


/* Quando for zero, fica “neutro” */
.tab-badge.is-zero{
  background:rgba(148,163,184,.12);
  color:rgba(148,163,184,.9);
  border:1px solid rgba(148,163,184,.25);
}


/* quando você esconder o topo ao rolar, a faixa vai junto */
body.ui-hide-chrome .quick-users{
  transform: translateY(-120%);
  opacity: 0;
  transition: transform .18s ease, opacity .18s ease;
}

/* Avatar padrão (composer + posts) */
.avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  overflow: hidden;
  display: grid;
  place-items: center;
  background: rgba(15, 23, 42, .55);
  border: 1px solid rgba(148, 163, 184, .12);
  flex: 0 0 44px;
}

.avatar img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.avatar .avatar-fallback{
  font-size: 22px;
  line-height: 1;
  transform: translateY(1px); /* só pra ficar no centro visual */
}

/* Se quiser o avatar do composer um pouco maior */
.composer .avatar{
  width: 46px;
  height: 46px;
  flex-basis: 46px;
}
/* quando rola pra baixo: some com o “chrome” todo */
@media (max-width: 900px){
  body.ui-hide-chrome .topbar,
  body.ui-hide-chrome .composer,
  body.ui-hide-chrome .quick-users{
    transform: translateY(-120%);
    opacity: 0;
    pointer-events: none;
    transition: transform .18s ease, opacity .18s ease;
  }

  /* opcional: some a barra de baixo também (Twitter vibes) */
  body.ui-hide-chrome .mobile-nav{
    transform: translateY(120%);
    opacity: 0;
    pointer-events: none;
    transition: transform .18s ease, opacity .18s ease;
  }
}

/* =========================
   CHROME MOBILE – ANIMAÇÃO SUAVE (AJUSTADO)
   ========================= */

/* Topo (topbar + abas + quick users) */
.topbar,
.feed-tabs,
.quick-users,
.composer{
  /* Aumentando a duração do transform para um movimento mais "pesado" */
  transition:
    transform .35s cubic-bezier(.4,0,.2,1),
    /* Opacidade acompanha o movimento, garantindo o 'fade' */
    opacity   .35s ease;
  will-change: transform;
}

/* Nav inferior */
.mobile-nav {
  transition:
    transform .35s cubic-bezier(.4,0,.2,1),
    opacity   .35s ease;
  will-change: transform;
}

/* Estado NORMAL */
body.page-feed .topbar,
body.page-feed .feed-tabs,
body.page-feed .quick-users {
  transform: translateY(0);
  opacity: 1;
}

body.page-feed .mobile-nav {
  transform: translateY(0);
  opacity: 1;
}

/* =========================
   ESCONDIDO (SCROLL DOWN)
   ========================= */

body.page-feed.ui-hide-chrome .topbar,
body.page-feed.ui-hide-chrome .feed-tabs,
body.page-feed.ui-hide-chrome .quick-users {
  transform: translateY(-110%);
  opacity: 0;
  pointer-events: none;
}

body.page-feed.ui-hide-chrome .mobile-nav {
  transform: translateY(110%);
  opacity: 0;
  pointer-events: none;
}

@media (max-width: 900px){
  body.page-feed .topbar,
  body.page-feed .feed-tabs,
  body.page-feed .quick-users,
  body.page-feed .composer{
    transition: transform .26s ease, opacity .26s ease;
  }

  body.page-feed.ui-hide-chrome .topbar,
  body.page-feed.ui-hide-chrome .feed-tabs,
  body.page-feed.ui-hide-chrome .quick-users,
  body.page-feed.ui-hide-chrome .composer{
    transition-delay: 0s, .06s; /* transform sem delay, opacity com delay */
  }
}

/* =========================================================
   TAPEADA: TOPBAR some mais suave (fade-out lento)
   - Só afeta a saída (quando ui-hide-chrome liga)
   - Entrada continua rápida e bonita
   ========================================================= */
@media (max-width: 900px){

  /* Transição padrão (já deve existir, mas aqui a gente reforça só o topo) */
  body.page-feed .topbar,
  body.page-feed .feed-tabs,
  body.page-feed .quick-users,
  body.page-feed .composer{
    transition:
      transform .30s cubic-bezier(.2,.9,.2,1),
      opacity   .38s ease;             /* opacidade mais lenta */
    will-change: transform, opacity;
  }

  /* Quando esconder: dá um delayzinho na opacidade pra não “piscar” */
  body.page-feed.ui-hide-chrome .topbar,
  body.page-feed.ui-hide-chrome .feed-tabs,
  body.page-feed.ui-hide-chrome .quick-users,
  body.page-feed.ui-hide-chrome .composer{
    transform: translateY(-10px);
    opacity: 0;

    transition-delay: 1s, .08s;        /* transform sem delay, opacity com delay */
    pointer-events: none;
  }

  /* Opcional: quick-users e composer podem continuar como estão.
     Se quiser eles um pouco mais “rápidos” que o topo (fica premium): */
  body.page-feed .topbar,
  body.page-feed .feed-tabs,
  body.page-feed .quick-users,
  body.page-feed .composer{
    transition: transform .22s ease, opacity .22s ease;
  }

  body.page-feed.ui-hide-chrome .topbar,
  body.page-feed.ui-hide-chrome .feed-tabs,
  body.page-feed.ui-hide-chrome .quick-users,
  body.page-feed.ui-hide-chrome .composer{
    transform: translateY(-8px);
    opacity: 0;
    pointer-events: none;
  }
}

/* =========================================================
   POOSTAKI — CHROME MOBILE (CANÔNICO, SEM BRIGA)
   - ÚNICA fonte da verdade pro hide/show no scroll
   - Evita duplicação de transition + ui-hide-chrome
   - Só no feed (não afeta profile/vitrine)
   ========================================================= */



/* MOBILE only */
@media (max-width: 900px){

  /* Estado normal (visível) */
  body.page-feed:not(.page-profile) .topbar,
  body.page-feed:not(.page-profile) .feed-tabs,
  body.page-feed:not(.page-profile) .quick-users,
  body.page-feed:not(.page-profile) .composer,
  body.page-feed:not(.page-profile) .mobile-nav{
    transform: translate3d(0,0,0);
    opacity: 1;
    pointer-events: auto;
    will-change: transform, opacity;
  }

  /* Transição padrão (entrada rápida, saída suave) */
  body.page-feed:not(.page-profile) .topbar,
  body.page-feed:not(.page-profile) .feed-tabs,
  body.page-feed:not(.page-profile) .quick-users,
  body.page-feed:not(.page-profile) .composer{
    transition:
      transform var(--chrome-in) var(--chrome-ease),
      opacity   var(--chrome-in) ease;
  }

  body.page-feed:not(.page-profile) .mobile-nav{
    transition:
      transform var(--chrome-in) var(--chrome-ease),
      opacity   var(--chrome-in) ease;
  }

  /* =========================
     ESCONDIDO (scroll down)
     ========================= */
  body.page-feed:not(.page-profile).ui-hide-chrome .topbar,
  body.page-feed:not(.page-profile).ui-hide-chrome .feed-tabs,
  body.page-feed:not(.page-profile).ui-hide-chrome .quick-users,
  body.page-feed:not(.page-profile).ui-hide-chrome .composer{
    transform: translate3d(0, var(--chrome-top-hide), 0);
    opacity: 0;
    pointer-events: none;
    transition:
      transform var(--chrome-out) var(--chrome-ease),
      opacity   var(--chrome-fade) ease;
  }

  body.page-feed:not(.page-profile).ui-hide-chrome .mobile-nav{
    transform: translate3d(0, var(--chrome-bot-hide), 0);
    opacity: 0;
    pointer-events: none;
    transition:
      transform var(--chrome-out) var(--chrome-ease),
      opacity   var(--chrome-fade) ease;
  }

  /* Acessibilidade: respeita quem não curte animação */
  @media (prefers-reduced-motion: reduce){
    body.page-feed:not(.page-profile) .topbar,
    body.page-feed:not(.page-profile) .feed-tabs,
    body.page-feed:not(.page-profile) .quick-users,
    body.page-feed:not(.page-profile) .composer,
    body.page-feed:not(.page-profile) .mobile-nav{
      transition: none !important;
      transform: none !important;
      opacity: 1 !important;
      pointer-events: auto !important;
    }
  }
}
/* =========================================================
   iOS SAFARI: evita “sumir” conteúdo por causa da barra do navegador
   ========================================================= */


.page-feed .center{
  padding-bottom: calc(var(--mnav-h, 56px) + env(safe-area-inset-bottom) + 12px);
}

@supports (-webkit-touch-callout: none){
  .page-feed .center{
    padding-bottom: calc(var(--mnav-h, 56px) + env(safe-area-inset-bottom) + var(--ios-browser-h));
  }
}

@media (max-width: 720px){
  .quick-user[data-handle]::after{
    bottom: 2px;
    max-width: 46px;
    padding: 2px 6px;
    font-size: 10px;
  }
}

/* =========================================================
   NOTIFICAÇÕES (scoped)
   ========================================================= */
body.page-notificacoes .notif-feed{
  padding-top: 8px;
}

body.page-notificacoes .notif-panel[hidden]{
  display: none !important;
}

/* opcional: não-lida com um glowzinho */
body.page-notificacoes .notif-item.is-unread{
  box-shadow: inset 0 0 0 1px rgba(34,197,94,.25);
}

/* badge 0 discreto (se você aplicar a classe .is-zero no PHP/JS) */
body.page-notificacoes .tab-badge.is-zero{
  background: rgba(148,163,184,.10);
  color: rgba(148,163,184,.85);
  border-color: rgba(148,163,184,.18);
}

.notif-tools-top{
  position: sticky;
  top: 8px;           /* ajuste se sua topbar/tabs forem fixas */
  z-index: 5;
  padding: 8px 0;
  background: rgba(2, 6, 23, .75); /* combina com o fundo escuro */
  backdrop-filter: blur(6px);
}


/* =========================================================
   NOTIFICAÇÕES - TABS (compactas e distribuídas)
   ========================================================= */
body.page-notificacoes .notif-tabs{
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
  padding: 8px 10px;
  border-bottom: 1px solid var(--line);
}

body.page-notificacoes .notif-tabs .tab{
  min-width: 0;
  padding: 8px 6px;
  font-size: 12px;
  line-height: 1.2;
  border-radius: 999px;

  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;

  /* NÃO corta o botão inteiro */
  overflow: visible;
}

body.page-notificacoes .notif-tabs .tab .tab-text{
  min-width: 0;
  flex: 1 1 auto;

  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;

  text-align: center;
}

body.page-notificacoes .notif-tabs .tab-badge{
  flex: 0 0 auto;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  font-size: 11px;
  line-height: 18px;
  border-radius: 999px;
}

@media (max-width: 420px){
  body.page-notificacoes .notif-tabs{
    gap: 4px;
    padding: 6px 6px;
  }
  body.page-notificacoes .notif-tabs .tab{
    padding: 7px 4px;
    font-size: 11px;
    gap: 5px;
  }
  body.page-notificacoes .notif-tabs .tab-badge{
    min-width: 16px;
    height: 16px;
    line-height: 16px;
    font-size: 10px;
  }
}



.page-notificacoes .notif-link{
  display:block;
  color:inherit;
  text-decoration:none;
}

.page-notificacoes .notif-preview{
  margin-top:6px;
  color: var(--txt-secondary);
  font-size: 12px;
  overflow:hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mobile-nav .nav-item.nav-bell{ position:relative; }

.mobile-nav .nav-badge{
  position:absolute;
  top:6px;
  right:10px;
  min-width:18px;
  height:18px;
  padding:0 5px;
  border-radius:999px;
  font-size:11px;
  line-height:18px;
  font-weight:900;
  text-align:center;
  pointer-events:none;

  background: rgba(34,197,94,.22);
  color: rgba(209,250,229,.95);
  border: 1px solid rgba(34,197,94,.35);
}

@media (max-width: 420px){
  .mobile-nav .nav-badge{ top:5px; right:9px; min-width:16px; height:16px; line-height:16px; font-size:10px; }
}

.btn-contact{
  margin-left:10px;
  padding:8px 10px;
  border-radius:10px;
  border:1px solid rgba(255,255,255,.12);
  background:rgba(34,211,238,.15);
  color:var(--txt-primary);
  font-weight:800;
}
.btn-contact:active{ transform:scale(.98); }
.ad-contact-mask{ color:var(--txt-secondary); }
.ad-contact-revealed{ margin-left:10px; font-weight:900; }

/* ==========================================================================
   ANÚNCIOS — MOBILE FIXES (iOS zoom + texto escapando)
   ========================================================================== */

/* iOS Safari: evita zoom em input/textarea < 16px */
.page-anuncios .th-comments textarea,
.page-anuncios .th-inline-form textarea{
  font-size:16px;
  line-height:1.35;
}

/* Texto não pode estourar a tela */
.page-anuncios .th-comments,
.page-anuncios .th-comments *{
  min-width:0;
}

.page-anuncios .th-comment,
.page-anuncios .th-reply,
.page-anuncios .th-comment-body,
.page-anuncios .ad-ch-left{
  overflow-wrap:anywhere;
  word-break:break-word;
}

/* Mantém quebras de linha do texto (JS manda texto escapado com \n) */
.page-anuncios .th-comment-body{
  white-space:pre-wrap;
}

/* Header do comentário: deixa tudo quebrar bonitinho no mobile */
.page-anuncios .th-comment-head{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:10px;
}

.page-anuncios .ad-ch-left{
  display:flex;
  flex-wrap:wrap;
  align-items:baseline;
  gap:4px 10px;
}

.th-comments-list > li.th-comment{
  padding: 10px 0;
  border-bottom: 1px solid rgba(148,163,184,.25);
}

.th-comments-list > li.th-comment:last-child{
  border-bottom: 0;
}

.th-replies{
  margin-top: 8px;
  padding-left: 12px;
  border-left: 2px solid rgba(148,163,184,.20);
}

.th-replies > li.th-reply{
  padding: 8px 0;
}


/* Botão não deve esmagar o layout */
.page-anuncios .th-reply-btn{
  flex:0 0 auto;
  white-space:nowrap;
}

/* Resposta do vendedor: visual mais limpo */
.page-anuncios .th-reply.is-owner-reply .muted.handle{
  display:none; /* some com o @ do vendedor nas replies */
}

/* Anti-bug: comentários do anúncio sumindo (só fica o <hr>) */
body.page-anuncios .th-comments-list,
body.page-anuncios .th-comments-list *{
  font-size: 15px !important;
  color: inherit;
}

body.page-anuncios .th-comments{
  color: var(--txt);
}


[hidden]{ display:none !important; }


body.search-open .page-feed main.center .topbar,
body.search-open .page-feed main.center .composer{
  transform: none !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}


/* =========================
   FEED: TOPBAR (Para você / Seguindo)
   - o pulo do gato: height = topbar + safe-top
   ========================= */
.page-feed .topbar{
  position: sticky;
  top: 0;
  z-index: 50;

  padding-top: var(--safe-top);
  height: calc(var(--topbar-h) + var(--safe-top));

  /* importante pra não ficar transparente em cima do conteúdo */
  backdrop-filter: blur(10px);
}

/* garante que as abas fiquem “no miolo” da topbar */
.page-feed .topbar .tabs{
  height: var(--topbar-h);
  display: flex;
  align-items: flex-end;
}

/* =========================
   MOBILE NAV: não brigar com a área de gesto (iOS)
   ========================= */
.mobile-nav{
  padding-bottom: var(--safe-bottom);
  height: calc(var(--mobile-nav-h) + var(--safe-bottom));
}

/* espaço pro conteúdo não ficar atrás da mobile-nav */
.page-feed .center{
  padding-bottom: calc(var(--mobile-nav-h) + var(--safe-bottom) + 24px);
}

.mobile-menu-overlay{
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.45);
  backdrop-filter: blur(6px);
  opacity: 0;
  transition: opacity .18s ease;
  z-index: 9998;
}

.mobile-menu-overlay.open{
  opacity: 1;
}

.mobile-menu-sheet{
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 9999;
  background: var(--card, #111);
  color: var(--text, #fff);
  border-top-left-radius: 18px;
  border-top-right-radius: 18px;
  transform: translateY(102%);
  transition: transform .18s ease;
  padding: 14px 14px calc(14px + env(safe-area-inset-bottom));
  max-height: 82vh;
  overflow: auto;
}

.mobile-menu-sheet.open{
  transform: translateY(0);
}

.mobile-menu-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 12px;
  padding: 6px 4px 12px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}

.mobile-menu-title{
  font-weight: 700;
  font-size: 16px;
}

.mobile-menu-close{
  border: 0;
  background: transparent;
  color: inherit;
  font-size: 20px;
  padding: 8px 10px;
  border-radius: 10px;
}

.mobile-menu-links{
  display: grid;
  gap: 8px;
  padding: 12px 0;
}

.mobile-menu-link{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 10px;
  padding: 12px 12px;
  border-radius: 12px;
  text-decoration:none;
  color: inherit;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.06);
}

.mobile-menu-link:active{
  transform: scale(.99);
}

.mobile-menu-link.is-disabled{
  opacity: .75;
  cursor: pointer;
}

.mobile-menu-link.danger{
  background: rgba(255,0,0,.12);
  border-color: rgba(255,0,0,.18);
}

.pill-soon{
  font-size: 12px;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(255,255,255,.10);
}

.pill-count{
  font-size: 12px;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(255,255,255,.12);
}

.dot-live{
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ff3b30;
  display:inline-block;
  margin-left: 8px;
}

.mobile-menu-pix{
  margin-top: 6px;
  padding-top: 12px;
  border-top: 1px solid rgba(255,255,255,.08);
}

.pix-title{
  font-weight: 700;
  margin-bottom: 10px;
  text-align:center;
}

.pix-qr{
  display:flex;
  justify-content:center;
  padding: 10px 0;
}
.pix-qr img{
  width: 150px;
  height: 150px;
  border-radius: 14px;
  background: #fff;
  padding: 6px;
}

.pix-row{
  display:flex;
  gap: 10px;
  align-items:center;
}

.pix-input{
  flex: 1;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.06);
  color: inherit;
  font-size: 13px;
}

.pix-btn{
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.10);
  color: inherit;
  font-weight: 700;
}

.pix-hint{
  margin-top: 8px;
  font-size: 13px;
  opacity: .9;
}
.pix-hint.ok{ color: #34c759; }
.pix-hint.err{ color: #ff3b30; }

/* ============================
   Patrocinar Sorteio (page scope)
   ============================ */
.page-patrocinar-sorteio .center{
  padding-bottom: 96px; /* evita trombar no install bar/PWA */
}

.page-patrocinar-sorteio .ps-wrap{
  padding: 14px 16px 20px;
}

.page-patrocinar-sorteio .ps-card{
  max-width: 980px;
  margin: 0 auto;
  border-radius: 18px;
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(2, 6, 23, .55);
  box-shadow: 0 10px 30px rgba(0,0,0,.25);
  overflow: hidden;

  display: grid;
  grid-template-columns: 1fr 1.1fr;
}

@media (max-width: 920px){
  .page-patrocinar-sorteio .ps-card{ grid-template-columns: 1fr; }
}

.page-patrocinar-sorteio .ps-hero{
  padding: 18px 18px 16px;
  border-right: 1px solid rgba(255,255,255,.08);
}

@media (max-width: 920px){
  .page-patrocinar-sorteio .ps-hero{ border-right: 0; border-bottom: 1px solid rgba(255,255,255,.08); }
}

.page-patrocinar-sorteio .ps-title{
  font-weight: 900;
  font-size: 20px;
  letter-spacing: .2px;
}

.page-patrocinar-sorteio .ps-sub{
  margin-top: 8px;
  opacity: .86;
  line-height: 1.35;
}

.page-patrocinar-sorteio .ps-bullets{
  margin: 12px 0 0;
  padding-left: 18px;
  opacity: .9;
}

.page-patrocinar-sorteio .ps-badge{
  display: inline-flex;
  gap: 8px;
  align-items: center;
  margin-top: 12px;
  padding: 8px 10px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,.10);
  background: rgba(15, 23, 42, .55);
  font-size: 13px;
  opacity: .92;
}

.page-patrocinar-sorteio .ps-formWrap{
  padding: 18px;
}

.page-patrocinar-sorteio .ps-grid{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

@media (max-width: 520px){
  .page-patrocinar-sorteio .ps-grid{ grid-template-columns: 1fr; }
}

.page-patrocinar-sorteio .ps-field{
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.page-patrocinar-sorteio .ps-field label{
  font-weight: 800;
  font-size: 13px;
  opacity: .95;
}

.page-patrocinar-sorteio .ps-input,
.page-patrocinar-sorteio .ps-textarea,
.page-patrocinar-sorteio .ps-file{
  width: 100%;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.06);
  color: inherit;
  outline: none;
}

.page-patrocinar-sorteio .ps-textarea{
  min-height: 110px;
  resize: vertical;
}

.page-patrocinar-sorteio .ps-help{
  font-size: 12px;
  opacity: .75;
}

.page-patrocinar-sorteio .ps-preview{
  margin-top: 8px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.12);
  overflow: hidden;
  background: rgba(0,0,0,.25);
}

.page-patrocinar-sorteio .ps-preview img{
  display: block;
  width: 100%;
  height: auto;
}

.page-patrocinar-sorteio .ps-actions{
  margin-top: 14px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}

.sponsor-banner{
  display:block;
  border-radius:16px;
  overflow:hidden;
  border:1px solid rgba(255,255,255,.12);
  margin: 10px 0 14px;
}
.sponsor-banner img{ width:100%; height:auto; display:block; }

/* =========================================
   FIX "ZEBRA" (dark topo + branco embaixo)
   Cole no FINAL do main.css
   ========================================= */

/* 1) Corpo sempre no tema */
body{
  background: var(--bg-body);
  color: var(--txt-primary);
}

/* 2) Área do feed não pinta de branco */
.page-feed :is(.feed, .timeline, .feed-list, .posts, main){
  background: transparent !important;
}

/* 3) Cards/posts no dark (cobre vários nomes comuns) */
.page-feed :is(
  .post, .post-card, .feed-card, .timeline-item,
  .card, .list-item, article, .item-post
){
  background: var(--bg-panel) !important;
  border: 1px solid var(--border) !important;
  color: var(--txt-primary) !important;
}

/* Textos “apagados” dentro dos cards */
.page-feed :is(.muted, .meta, .handle, .sub, .small, .time, .date){
  color: var(--txt-secondary) !important;
}

/* Ícones/ações dentro dos cards */
.page-feed :is(.actions a, .actions button, .post-actions a, .post-actions button){
  color: var(--txt-secondary) !important;
}
.page-feed :is(.actions a:hover, .post-actions a:hover){
  color: var(--txt-primary) !important;
}

/* 4) Nav mobile: se ela tá branca, é override. A gente passa o trator. */
@media (max-width: 720px){
  .mobile-nav{

    backdrop-filter: blur(10px);
    border-top: 1px solid var(--border) !important;
  }
  .mobile-nav a,
  .mobile-nav button{
    background: transparent !important;
    color: var(--txt-secondary) !important;
  }

  /* Evita a nav comer o último post */
  body{
    padding-bottom: calc(1px + env(safe-area-inset-bottom));
  }
}

