/* Página pública da Comunidade (proposta). Soma-se a public-site.css (páginas públicas v2),
   community-tour.css (destaque que passeia pelos canais) e community-guide.css (elo e demonstração). */
.pc {
  --text-primary: var(--text); --text-secondary: var(--text-2); --card-bg: var(--surface); --bg-secondary: var(--surface-2);
  --border-color: var(--border-strong); --primary: var(--brand); --on-primary: var(--brand-ink); --success: var(--up); --warning: var(--warn);
  --radius-lg: 18px; --fs-sm: 13.5px; --fs-xs: 12.5px;
  --cg-discord: #5865f2; --cg-discord-hover: #4752c4; --cg-soft: color-mix(in srgb, var(--text) 6%, transparent);
  --cg-ink-ok: color-mix(in srgb, var(--up) 45%, var(--text));
  --pc-discord: #5865f2;
}
.pc .visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }
.pc .cg-mark { filter: brightness(0) invert(1); }
.pc-center { display: flex; justify-content: center; margin-top: 40px; }
.pc-hero { padding-bottom: clamp(48px, 7vw, 96px); }
.pc-hero::after { background: radial-gradient(60% 60% at 50% 0%, rgba(88, 101, 242, .16), transparent 70%), var(--glow); }

/* Entrada suave das seções */
.pc-reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .7s cubic-bezier(.2, .8, .3, 1); transition-delay: calc(var(--r, 0) * 90ms); }
.pc-reveal.is-in { opacity: 1; transform: none; }

/* ---------- Explorador do servidor ---------- */
.pe { --ct-row: 34px; }
.pe .frame-url img { filter: brightness(0) invert(1); opacity: .7; }
html.light .pe .frame-url img { filter: none; opacity: .55; }
.pe-body { display: grid; grid-template-columns: minmax(230px, 300px) minmax(0, 1fr); min-height: 430px; background: var(--surface); }
.pe-list { position: relative; display: grid; align-content: start; gap: 1px; padding: 10px 8px 14px; border-right: 1px solid var(--border); background: var(--bg-2); }
.pe-cat { display: flex; gap: 8px; align-items: center; padding: 12px 10px 4px; color: var(--text-3); font-size: 10.5px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; }
.pe-cat span { padding: 1px 7px; border: 1px solid var(--border-strong); border-radius: 999px; font-size: 9.5px; letter-spacing: .05em; }
.pe-row { position: relative; z-index: 1; display: flex; gap: 8px; align-items: center; width: 100%; min-height: var(--ct-row); padding: 0 10px; border: 0; border-radius: 7px; background: transparent; color: var(--text-2); font: inherit; font-size: 14px; text-align: left; cursor: pointer; transition: color .25s ease; }
.pe-row:hover, .pe-row:focus-visible { color: var(--text); }
.pe-row:focus-visible { outline: 2px solid var(--pc-discord); outline-offset: -2px; }
.pe-row.is-spot { color: #fff; font-weight: 600; }
html.light .pe-row.is-spot { color: var(--text); }
.pe-row-type { width: 14px; height: 14px; flex: none; color: var(--text-3); }
.pe-row-emoji { width: 1.25em; text-align: center; transition: transform .35s cubic-bezier(.3, 1.6, .5, 1); }
.pe-row.is-spot .pe-row-emoji { transform: scale(1.25); }
.pe-row-lock { width: 12px; height: 12px; margin-left: auto; color: var(--text-3); }
.pe .pe-cat, .pe .pe-row { opacity: 0; transform: translateX(-10px); }
.pe.is-playing .pe-cat, .pe.is-playing .pe-row { opacity: 1; transform: none; transition: opacity .35s ease, transform .45s cubic-bezier(.2, .9, .3, 1), color .25s ease; transition-delay: calc(var(--i, 0) * 34ms + 180ms), calc(var(--i, 0) * 34ms + 180ms), 0s; }
.pe .ct-spot { right: 8px; left: 8px; height: var(--ct-row); border-radius: 7px; }
html.light .pe .ct-spot { background: linear-gradient(90deg, rgba(88, 101, 242, .22), rgba(88, 101, 242, .08)); box-shadow: 0 0 0 1px rgba(88, 101, 242, .45); }
html.light .pe .ct-spot-fx i { background: var(--pc-discord); }

.pe-stage { position: relative; display: grid; grid-template-rows: auto 1fr auto; min-width: 0; overflow: hidden; }
.pe-stage::before { position: absolute; top: -40%; right: -20%; width: 70%; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(closest-side, rgba(88, 101, 242, .12), transparent); content: ''; pointer-events: none; }
.pe-stage-head { position: relative; display: flex; gap: 14px; align-items: center; padding: 20px 24px 0; }
.pe-stage-emoji { display: grid; flex: none; width: 48px; height: 48px; place-items: center; border-radius: 14px; background: var(--surface-3); font-size: 24px; }
.pe-stage-head > div { display: grid; gap: 2px; min-width: 0; }
.pe-stage-head strong { font-size: clamp(1.15rem, 2vw, 1.5rem); font-weight: 750; letter-spacing: -.02em; }
.pe-stage-head small { color: var(--text-3); font-size: 12.5px; }
.pe-stage-tag { display: inline-flex; gap: 6px; align-items: center; margin-left: auto; padding: 4px 10px; border: 1px solid var(--brand-line); border-radius: 999px; background: var(--brand-soft); color: color-mix(in srgb, var(--brand) 70%, var(--text)); font-size: 11.5px; font-weight: 700; }
.pe-stage-tag[hidden] { display: none; }
.pe-stage-tag svg { width: 12px; height: 12px; }
.pe-stage.is-swapping .pe-stage-emoji { animation: pe-pop .5s cubic-bezier(.3, 1.6, .5, 1) 1; }
.pe-stage.is-swapping .pe-stage-head > div, .pe-stage.is-swapping .pe-stage-foot p { animation: pe-rise .4s cubic-bezier(.2, .9, .3, 1) 1; }
@keyframes pe-pop { from { transform: scale(.6) rotate(-12deg); } to { transform: none; } }
@keyframes pe-rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.pe-scenes { position: relative; display: grid; padding: 22px 24px; }
.pe-scene[data-scene="chat"], .pe-scene[data-scene="forum"], .pe-scene[data-scene="status"], .pe-scene[data-scene="midia"] { width: min(100%, 640px); margin-inline: auto; }
.pe-scene { grid-area: 1 / 1; display: grid; gap: 16px; align-content: center; opacity: 0; visibility: hidden; transform: translateY(10px) scale(.985); transition: opacity .3s ease, transform .45s cubic-bezier(.2, .9, .3, 1), visibility 0s linear .3s; }
.pe-stage[data-scene="chat"] .pe-scene[data-scene="chat"], .pe-stage[data-scene="forum"] .pe-scene[data-scene="forum"], .pe-stage[data-scene="voice"] .pe-scene[data-scene="voice"],
.pe-stage[data-scene="doc"] .pe-scene[data-scene="doc"], .pe-stage[data-scene="aviso"] .pe-scene[data-scene="aviso"], .pe-stage[data-scene="midia"] .pe-scene[data-scene="midia"],
.pe-stage[data-scene="status"] .pe-scene[data-scene="status"], .pe-stage[data-scene="inicio"] .pe-scene[data-scene="inicio"] { opacity: 1; visibility: visible; transform: none; transition-delay: .08s, .08s, 0s; }
/* Esqueletos com contraste suficiente nos dois temas. */
.pe-scene .skel { height: 10px; border-radius: 5px; background: linear-gradient(90deg, color-mix(in srgb, var(--text) 13%, transparent), color-mix(in srgb, var(--text) 24%, transparent), color-mix(in srgb, var(--text) 13%, transparent)); background-size: 200% 100%; }
.pe-lines { display: grid; flex: 1; gap: 8px; min-width: 0; }
.pe-av { flex: none; width: 40px; height: 40px; border-radius: 50%; background: linear-gradient(135deg, color-mix(in srgb, var(--text) 26%, transparent), color-mix(in srgb, var(--text) 10%, transparent)); }
.pe-av--sm { width: 24px; height: 24px; }
.pe-msg, .pe-thread, .pe-status, .pe-typing { display: flex; gap: 12px; align-items: flex-start; }
/* Cada cena só anima enquanto está em cartaz. */
.pe-scene .pe-msg, .pe-scene .pe-thread, .pe-scene .pe-status { opacity: 0; }
.pe-stage[data-scene="chat"] .pe-scene[data-scene="chat"] .pe-msg, .pe-stage[data-scene="midia"] .pe-scene[data-scene="midia"] .pe-msg,
.pe-stage[data-scene="forum"] .pe-scene[data-scene="forum"] .pe-thread, .pe-stage[data-scene="status"] .pe-scene[data-scene="status"] .pe-status { animation: pe-in .45s cubic-bezier(.2, .9, .3, 1) calc(var(--d, 0) * 220ms + 150ms) 1 both; }
@keyframes pe-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.pe-typing { align-items: center; color: var(--text-3); }
.pe-dots { display: inline-flex; gap: 4px; padding: 8px 12px; border-radius: 999px; background: var(--surface-3); }
.pe-dots i { width: 6px; height: 6px; border-radius: 50%; background: var(--text-2); animation: ct-typing 1.1s ease-in-out infinite; }
.pe-dots i:nth-child(2) { animation-delay: .15s; }
.pe-dots i:nth-child(3) { animation-delay: .3s; }
.pe-thread { align-items: center; padding: 12px 14px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-2); }
.pe-thread-ic { display: grid; flex: none; width: 34px; height: 34px; place-items: center; border-radius: 10px; background: var(--surface-3); color: var(--text-2); }
.pe-thread-ic svg { width: 16px; height: 16px; }
.pe-pill { flex: none; width: 38px; height: 20px; border-radius: 999px; background: color-mix(in srgb, var(--text) 12%, transparent); }
.pe-pill--ok { width: 46px; background: var(--brand-soft); box-shadow: inset 0 0 0 1px var(--brand-line); }
.pe-status { align-items: center; padding: 12px 14px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-2); }
.pe-status .skel { flex: 1; max-width: 60%; margin-right: auto; }
.pe-table { display: flex; gap: clamp(12px, 3vw, 28px); justify-content: center; padding-top: 6px; }
.pe-seat { position: relative; width: clamp(52px, 8vw, 84px); aspect-ratio: 1; border-radius: 50%; background: linear-gradient(135deg, color-mix(in srgb, var(--text) 26%, transparent), color-mix(in srgb, var(--text) 10%, transparent)); }
.pe-seat.is-talking { box-shadow: 0 0 0 3px var(--surface), 0 0 0 5px var(--up); }
.pe-seat.is-talking::after { position: absolute; inset: -5px; border: 2px solid var(--up); border-radius: 50%; content: ''; animation: pe-ring 1.6s ease-out infinite; }
.pe-seat--late.is-talking, .pe-seat--late.is-talking::after { animation-delay: .8s; }
.pe-seat--late.is-talking { animation: pe-talk 3.2s steps(1) infinite; }
@keyframes pe-ring { from { opacity: .8; transform: scale(1); } to { opacity: 0; transform: scale(1.5); } }
@keyframes pe-talk { 0%, 49% { box-shadow: none; } 50%, 100% { box-shadow: 0 0 0 3px var(--surface), 0 0 0 5px var(--up); } }
.pe-eq { display: flex; gap: 4px; align-items: center; justify-content: center; height: 46px; }
.pe-eq i { width: 4px; height: 100%; border-radius: 3px; background: var(--pc-discord); transform: scaleY(.2); animation: ct-eq .9s ease-in-out calc(var(--i) * -70ms) infinite; }
.pe-eq i:nth-child(3n) { animation-duration: 1.2s; }
.pe-eq i:nth-child(4n) { animation-duration: .7s; }
.pe-note { display: inline-flex; gap: 8px; align-items: center; justify-self: center; padding: 6px 12px; border-radius: 999px; background: var(--surface-3); color: var(--text-2); font-size: 12.5px; font-weight: 600; }
.pe-note svg { width: 14px; height: 14px; color: var(--up); }
.pe-doc, .pe-card { display: grid; gap: 13px; width: min(100%, 540px); margin-inline: auto; padding: 20px; border: 1px solid var(--border); border-radius: 14px; background: var(--surface-2); }
.pe-doc-tag { display: inline-flex; gap: 6px; align-items: center; justify-self: start; padding: 4px 10px; border-radius: 999px; background: var(--brand-soft); color: color-mix(in srgb, var(--brand) 70%, var(--text)); font-size: 11.5px; font-weight: 700; }
.pe-doc-tag svg { width: 13px; height: 13px; }
.pe-bell { display: grid; justify-self: center; width: 56px; height: 56px; place-items: center; border-radius: 50%; background: var(--warn-bg, rgba(245, 158, 11, .14)); color: var(--warn); }
.pe-bell svg { width: 26px; height: 26px; transform-origin: 50% 10%; animation: pe-bell 2.4s ease-in-out infinite; }
@keyframes pe-bell { 0%, 60%, 100% { transform: rotate(0); } 10%, 30% { transform: rotate(14deg); } 20%, 40% { transform: rotate(-14deg); } 50% { transform: rotate(6deg); } }
.pe-shot { display: grid; height: 96px; place-items: center; border: 1px dashed var(--border-strong); border-radius: 12px; background: var(--surface-2); color: var(--text-3); }
.pe-shot svg { width: 26px; height: 26px; }
.pe-reacts { display: flex; gap: 6px; }
.pe-reacts b { padding: 3px 9px; border-radius: 999px; background: var(--surface-3); font-size: 13px; font-weight: 400; animation: pe-react 2.6s ease-in-out infinite; }
.pe-reacts b:nth-child(2) { animation-delay: .4s; }
.pe-reacts b:nth-child(3) { animation-delay: .8s; }
@keyframes pe-react { 0%, 80%, 100% { transform: none; } 88% { transform: translateY(-4px) scale(1.12); } }
.pe-card--start strong { font-size: 15px; }
.pe-validate { justify-self: start; padding: 8px 14px; border-radius: 8px; background: #248046; color: #fff; font-size: 13px; font-weight: 600; animation: dd-hint 1.6s ease-in-out infinite; }

.pe-stage-foot { position: relative; padding: 0 24px 22px; }
.pe-stage-foot p { max-width: 60ch; margin: 0; color: var(--text-2); font-size: clamp(.95rem, 1.3vw, 1.08rem); line-height: 1.55; }
.pe-stage-foot .ct-progress { right: 24px; bottom: 10px; left: 24px; border-radius: 3px; overflow: hidden; }
.pe-hint { display: flex; gap: 8px; align-items: center; justify-content: center; margin: 16px 0 0; color: var(--text-3); font-size: 13px; }
.pe-hint svg { width: 15px; height: 15px; }

/* ---------- Por que entrar ---------- */
.pc-why { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.pc-why .pc-reveal:nth-child(2) { --r: 1; } .pc-why .pc-reveal:nth-child(3) { --r: 2; } .pc-why .pc-reveal:nth-child(4) { --r: 3; }
.pc-why-card { position: relative; display: grid; gap: 10px; align-content: start; overflow: hidden; padding: 24px; border: 1px solid var(--border); border-radius: 18px; background: var(--surface); transition: transform .25s ease, border-color .25s ease, opacity .6s ease; }
.pc-why-card::before { position: absolute; top: -60%; left: -30%; width: 120%; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(closest-side, var(--brand-soft), transparent); content: ''; opacity: 0; transition: opacity .35s ease; }
.pc-why-card:hover { border-color: var(--border-strong); transform: translateY(-4px); }
.pc-why-card:hover::before, .pc-why-card--brand::before { opacity: 1; }
.pc-why-card--brand { border-color: var(--brand-line); }
.pc-why-ic { position: relative; display: grid; width: 44px; height: 44px; place-items: center; border-radius: 12px; background: var(--surface-3); color: var(--text); }
.pc-why-card--brand .pc-why-ic { background: var(--brand); color: var(--brand-ink); }
.pc-why-ic svg { width: 20px; height: 20px; }
.pc-why-card h3 { position: relative; margin: 6px 0 0; font-size: 1.12rem; font-weight: 700; letter-spacing: -.015em; line-height: 1.25; }
.pc-why-card p { position: relative; margin: 0; color: var(--text-2); font-size: 14.5px; line-height: 1.6; }

/* ---------- Entrada ---------- */
.pc-entry { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(24px, 4vw, 56px); align-items: center; }
.pc-steps { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.pc-step { position: relative; display: flex; gap: 16px; align-items: flex-start; width: 100%; overflow: hidden; padding: 18px 20px; border: 1px solid var(--border); border-radius: 16px; background: transparent; color: var(--text); font: inherit; text-align: left; cursor: pointer; transition: border-color .25s ease, background-color .25s ease; }
.pc-step:hover { border-color: var(--border-strong); }
.pc-step:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.pc-step b { display: grid; flex: none; width: 34px; height: 34px; place-items: center; border: 1px solid var(--border-strong); border-radius: 50%; color: var(--text-2); font-size: 14px; transition: background-color .25s ease, color .25s ease, border-color .25s ease; }
.pc-step > span { display: grid; gap: 4px; min-width: 0; }
.pc-step strong { font-size: 1.08rem; font-weight: 700; letter-spacing: -.01em; }
.pc-step small { display: none; color: var(--text-2); font-size: 14.5px; line-height: 1.55; }
.pc-step.is-on { border-color: var(--brand-line); background: var(--surface); }
.pc-step.is-on b { border-color: var(--brand); background: var(--brand); color: var(--brand-ink); }
.pc-step.is-on small { display: block; animation: pe-rise .35s cubic-bezier(.2, .9, .3, 1) 1; }
.pc-step-bar { position: absolute; bottom: 0; left: 0; width: 0; height: 3px; background: var(--brand); }
.pc-entry.is-auto .pc-step.is-on .pc-step-bar { animation: ct-progress var(--pc-dwell, 4000ms) linear 1 forwards; }
.pc-entry-stage { min-width: 0; }
.pc-entry-panel[hidden] { display: none; }
.pc-entry-panel { animation: pe-rise .4s cubic-bezier(.2, .9, .3, 1) 1; }
.pc-entry-panel--link { padding: clamp(24px, 4vw, 44px); border: 1px solid var(--border); border-radius: 18px; background: var(--surface); }
.pc-entry-panel--link .cl-tile { width: 4.2rem; height: 4.2rem; border-radius: 1.2rem; }
.pc-entry-panel--link .cl-tile--id svg { width: 1.6rem; height: 2.4rem; }
.pc-entry-panel--link .cl-tile--discord .cg-mark { width: 2.1rem; }
.pc-entry-panel--link .cl-status { margin-top: 6px; font-size: 14.5px; }

/* ---------- É / não é ---------- */
.pc-claims, .pc-plans { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; max-width: 980px; margin-inline: auto; }
.pc-claims .pc-reveal:nth-child(2), .pc-plans .pc-reveal:nth-child(2) { --r: 1; }
.pc-claim, .pc-plan { display: grid; gap: 14px; align-content: start; padding: 26px; border: 1px solid var(--border); border-radius: 18px; background: var(--surface); }
.pc-claim h3 { margin: 0; color: var(--text-3); font-size: 12px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; }
.pc-claim ul, .pc-plan ul { display: grid; gap: 12px; margin: 0; padding: 0; list-style: none; }
.pc-claim li, .pc-plan li { display: flex; gap: 12px; align-items: flex-start; font-size: 15px; line-height: 1.5; }
.pc-claim li svg, .pc-plan li svg { flex: none; width: 22px; height: 22px; padding: 4px; border-radius: 50%; }
.pc-claim--yes li svg, .pc-plan li svg { background: var(--brand-soft); color: var(--brand); }
.pc-claim--no li { color: var(--text-2); }
.pc-claim--no li svg { background: var(--surface-3); color: var(--text-3); }

/* ---------- Preço ---------- */
.pc-plan--paid { border-color: var(--brand-line); background: linear-gradient(160deg, var(--brand-soft), transparent 55%), var(--surface); }
.pc-plan-tag { color: var(--text-3); font-size: 12px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; }
.pc-plan-price { margin: 0; font-size: 2.6rem; font-weight: 800; letter-spacing: -.04em; line-height: 1; }
.pc-plan-price--text { padding-block: .55rem .1rem; font-size: 1.45rem; letter-spacing: -.02em; }
.pc-plan .btn { margin-top: 8px; }
.pc-founder { display: grid; gap: 10px; justify-items: center; max-width: 760px; margin: 48px auto 0; text-align: center; }
.pc-founder p { margin: 0; color: var(--text-2); font-size: 1.08rem; line-height: 1.65; text-wrap: pretty; }

.pc-final-mark { display: grid; width: 60px; height: 60px; place-items: center; border-radius: 16px; background: var(--pc-discord); box-shadow: 0 18px 40px -14px rgba(88, 101, 242, .8); }
.pc-final-mark img { filter: brightness(0) invert(1); }
html body .pc-sticky { display: none; }

@media (max-width: 1020px) {
  .pc-why { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pc-entry { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 767.98px) {
  /* No celular a cena vem primeiro e os canais viram uma grade de botões. */
  .pe-body { grid-template-columns: minmax(0, 1fr); min-height: 0; }
  .pe-stage { order: -1; min-height: 330px; }
  .pe-list { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; padding: 12px; border-top: 1px solid var(--border); border-right: 0; }
  .pe-cat { display: none; }
  .pe .pe-row { min-height: 40px; border: 1px solid var(--border); background: var(--surface); font-size: 13.5px; opacity: 1; transform: none; }
  .pe-row.is-spot { border-color: var(--pc-discord); background: rgba(88, 101, 242, .22); }
  .pe .ct-spot { display: none; }
  .pe-stage-head { padding: 16px 16px 0; }
  .pe-scenes { padding: 16px; }
  .pe-stage-foot { padding: 0 16px 20px; }
  .pe-stage-foot .ct-progress { right: 16px; left: 16px; }
  .pe-hint { display: none; }
  .pc-why, .pc-claims, .pc-plans { grid-template-columns: minmax(0, 1fr); }
  html body .pc-sticky { position: fixed; right: 14px; bottom: calc(14px + env(safe-area-inset-bottom)); left: 14px; z-index: 40; display: flex; box-shadow: 0 14px 34px rgba(0, 0, 0, .45); opacity: 0; pointer-events: none; transform: translateY(12px); transition: opacity .2s ease, transform .2s ease; }
  html body .pc-sticky.is-visible { opacity: 1; pointer-events: auto; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  .pc-reveal { opacity: 1; transform: none; transition: none; }
  .pe .pe-cat, .pe .pe-row, .pe-scene .pe-msg, .pe-scene .pe-thread, .pe-scene .pe-status { opacity: 1; transform: none; animation: none !important; transition: none; }
  .pe-dots i, .pe-eq i, .pe-seat.is-talking::after, .pe-seat--late.is-talking, .pe-bell svg, .pe-reacts b, .pe-validate, .pc-step-bar { animation: none !important; }
  .pe-eq i { transform: scaleY(.6); }
}
