/* =========================================================================
   Salas, perfil e temas — logo nova, salas com chat próprio, call minimizada,
   configurações com abas e temas de cor. Carrega depois do style.css.
   ========================================================================= */

/* ---- logo ---- */
.logo-dock { width: 46px; height: 46px; flex: none; margin-bottom: 4px; cursor: default; filter: drop-shadow(0 4px 14px rgba(var(--lavanda-rgb), .45)); transition: transform .45s var(--mola), filter .3s; }
.logo-dock:hover { transform: scale(1.14) rotate(-5deg); filter: drop-shadow(0 6px 22px rgba(var(--gelo-rgb), .75)); }
.logo-hero { width: clamp(110px, 13vw, 168px); height: auto; margin: 0 0 22px 2px; filter: drop-shadow(0 10px 40px rgba(var(--lavanda-rgb), .5)); animation: logoIn 1.1s var(--mola) both, logoGlow 5s ease-in-out 1.2s infinite alternate; }
@keyframes logoIn { from { opacity: 0; transform: scale(.55) rotate(-16deg); filter: blur(12px); } }
@keyframes logoGlow { to { filter: drop-shadow(0 12px 58px rgba(var(--gelo-rgb), .75)); } }
.wheel, .logo-mark { display: none; }

/* ---- temas ---- */
html[data-tema="brasa"] { --lavanda-rgb: 255,196,86; --gelo-rgb: 255,94,94; --aur1: 255,70,40; --aur2: 160,20,60; --aur3: 255,150,30; --fundo-glow: #2a0f12; }
html[data-tema="floresta"] { --lavanda-rgb: 182,255,92; --gelo-rgb: 61,255,176; --aur1: 20,160,90; --aur2: 40,120,200; --aur3: 120,200,40; --fundo-glow: #0c2418; }
html[data-tema="neon"] { --lavanda-rgb: 255,90,214; --gelo-rgb: 90,240,255; --aur1: 200,40,220; --aur2: 40,120,255; --aur3: 255,60,160; --fundo-glow: #1a0d33; }

/* ---- modo leve (efeitos reduzidos) ---- */
html.lite .glass, html.lite dialog, html.lite #toast, html.lite .tile .label { backdrop-filter: none; }
html.lite .glass { background: rgba(16,18,36,.94); }
html.lite dialog { background: #0f1126; }
html.lite #aurora i { animation: none; }
html.lite body::after, html.lite .rip { display: none; }

/* ---- avatares com foto ---- */
.avatar.has-img { background-size: cover; background-position: center; color: transparent; text-shadow: none; }
.avatar.big { width: 84px; height: 84px; font-size: 34px; }
.avatar-btn { border-radius: 50%; padding: 0; transition: transform .3s var(--mola); }
.avatar-btn:hover { transform: scale(1.1); }
.avatar-btn .avatar { width: 34px; height: 34px; }

/* ---- centro: sala (roda + chat) ou só conversa ---- */
#chat-title { align-items: baseline; }
#chat-sub { color: var(--suave); font-size: 14px; margin-left: 4px; }
#chat-title .pill-btn, #chat-title .icon-btn { align-self: center; }
#main-body { flex: 1; min-height: 0; display: grid; grid-template-columns: minmax(0, 1fr); }
main.room #main-body { grid-template-columns: minmax(0, 1fr) var(--w-chat); }
#room-left { display: none; flex-direction: column; min-height: 0; overflow-y: auto; padding-bottom: 10px; scrollbar-width: none; }
main.room #room-left { display: flex; }
#room-left[hidden] { display: none !important; }
#chatcol { display: flex; flex-direction: column; min-height: 0; min-width: 0; }
main.room #chatcol { border-left: 1px solid var(--linha); background: rgba(0,0,0,.16); }
main.room #messages { padding: 10px 14px; }
.msg .body { font-size: 15.5px; }
main.room .msg { padding-right: 14px; }
.msg .text { line-height: 1.4; }
#room-left.fora #stage { display: none !important; }
#room-controls { display: flex; justify-content: center; gap: 10px; padding: 6px 12px 0; margin-top: auto; }
.round { min-width: 52px; height: 52px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; border-radius: 999px; background: var(--vidro-2); border: 1px solid var(--linha); font-size: 20px; transition: transform .25s var(--mola), background .2s; }
.round.wide { padding: 0 22px; font-size: 15px; font-weight: 600; }
.round:hover { transform: translateY(-3px) scale(1.05); background: rgba(255,255,255,.16); }
.round.danger { background: rgba(var(--rubi-rgb), .2); color: #ffc0cc; border-color: rgba(var(--rubi-rgb), .45); }
.round.danger:hover { background: var(--rubi); color: #fff; }
[data-act].on { background: var(--rubi) !important; color: #fff !important; }
.live { background: linear-gradient(120deg, var(--lavanda), var(--gelo)) !important; color: var(--tinta) !important; }
.forcado { opacity: .55; cursor: not-allowed; }
#room-join { margin: 10px 16px; padding: 32px 20px; border-radius: var(--r-lg); text-align: center; background: rgba(0,0,0,.22); border: 1px dashed var(--linha); animation: pop .5s var(--mola); }
#room-join p { margin: 0 0 16px; color: var(--suave); }

/* ---- a call minimizada nos 4 cantos ---- */
#minicall { position: fixed; z-index: 12; left: 0; top: 0; width: 268px; padding: 10px 12px 12px; border-radius: 24px; transition: left .5s var(--mola), top .5s var(--mola), opacity .3s; animation: pop .5s var(--mola); }
#minicall.drag { transition: none; box-shadow: 0 30px 60px -20px #000, 0 0 0 1px rgba(var(--gelo-rgb), .55); }
.mc-head { display: flex; align-items: center; gap: 9px; padding: 2px 2px 9px; cursor: grab; user-select: none; touch-action: none; }
#minicall.drag .mc-head { cursor: grabbing; }
.mc-head b { flex: 1; min-width: 0; font: 700 14px var(--titulo); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#mc-avatars { display: flex; gap: 6px; flex-wrap: wrap; padding: 0 2px 10px; }
#mc-avatars .avatar { width: 34px; height: 34px; font-size: 14px; }
.mc-controls { display: flex; gap: 8px; justify-content: space-between; }
.mc-controls .icon-btn { width: 44px; height: 38px; border-radius: 14px; }
.mc-controls .icon-btn.danger { background: rgba(var(--rubi-rgb), .2); }

/* ---- configurações com abas ---- */
dialog.wide { width: min(580px, 94vw); }
.tabs-h { display: flex; gap: 4px; margin-bottom: 14px; padding: 4px; border-radius: 999px; background: rgba(0,0,0,.28); }
.tabs-h button { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 9px 8px; border-radius: 999px; color: var(--suave); font-weight: 600; font-size: 14px; transition: background .25s, color .25s; }
.tabs-h button:hover { color: var(--espuma); }
.tabs-h button.on { background: linear-gradient(120deg, var(--lavanda), var(--gelo)); color: var(--tinta); }
dialog section[data-pane] { animation: sobe-leve .35s var(--suave-out) both; }
dialog section[hidden] { display: none; }
dialog h4 { margin: 18px 0 2px; font: 700 16px var(--titulo); }
.prof-head { display: flex; align-items: center; gap: 18px; margin-bottom: 6px; }
.prof-btns { display: grid; gap: 8px; }
#pf-crop { display: grid; justify-items: center; gap: 8px; margin: 10px 0; padding: 14px; border-radius: 22px; background: rgba(0,0,0,.28); animation: pop .35s var(--mola); }
#pf-crop[hidden] { display: none; }
#pf-canvas { width: 210px; height: 210px; border-radius: 50%; cursor: grab; background: #000; box-shadow: 0 0 0 3px var(--linha), 0 20px 40px -18px #000; touch-action: none; }
.swatches { display: flex; flex-wrap: wrap; gap: 9px; }
.swatches button { width: 30px; height: 30px; border-radius: 50%; border: 2px solid transparent; transition: transform .25s var(--mola), border-color .2s; }
.swatches button:hover { transform: scale(1.15); }
.swatches button.on { border-color: #fff; transform: scale(1.18); }
.themes { display: flex; flex-wrap: wrap; gap: 10px; }
.themes button { display: grid; gap: 7px; justify-items: center; padding: 10px 12px; border-radius: 18px; background: var(--vidro-2); border: 2px solid transparent; font-size: 13px; transition: transform .25s var(--mola), border-color .2s; }
.themes button:hover { transform: translateY(-3px); }
.themes button i { display: block; width: 64px; height: 28px; border-radius: 10px; }
.themes button.on { border-color: var(--gelo); }
#pf-msg { min-height: 1.3em; }
#pf-msg.erro { color: #ff9db0; }

/* ---- perfil de uma pessoa ---- */
.mb-head { display: flex; align-items: center; gap: 16px; margin-bottom: 4px; }
.mb-head h3 { margin: 0; }
.mb-head .hint { margin: 2px 0 0; }
.mod-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin: 8px 0; }
.mod-grid button { padding: 10px 6px !important; font-size: 13px; }
#mb-move-row { margin-top: 4px; }
#mb-vol { width: 100%; }

/* ---- turma: status debaixo do nome ---- */
.mrow .who { display: grid; min-width: 0; line-height: 1.2; }
.mrow .st { font-size: 12px; color: var(--suave); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#role-editor { margin: 10px 0; padding: 12px; border-radius: 20px; background: rgba(0,0,0,.25); animation: pop .3s var(--mola); }
#role-editor[hidden] { display: none; }
.role-row { cursor: pointer; padding: 6px 8px; border-radius: 12px; transition: background .2s; }
.role-row:hover { background: var(--vidro); }
#re-perms { display: grid; gap: 5px; margin: 8px 0; }

@media (max-width: 1180px) { main.room #main-body { grid-template-columns: minmax(0, 1fr) var(--w-chat-small, 300px); } }
@media (max-width: 860px) { main.room #main-body { grid-template-columns: minmax(0, 1fr); } main.room #chatcol { display: none; } }

/* ---- desempenho: modo leve (padrão) e pausa quando a janela perde o foco (você está no jogo) ---- */
html.lite #aurora i, html.pausa #aurora i { animation: none; translate: none; transition: none; will-change: auto; }
html.lite body::after, html.pausa body::after { display: none; }
html.lite .logo-hero, html.lite .wordmark, html.lite .seat .avatar, html.lite .roda-core, html.lite .badge, html.lite .badge::before, html.lite .vs-dot,
html.pausa .logo-hero, html.pausa .wordmark, html.pausa .seat .avatar, html.pausa .roda-core, html.pausa .badge, html.pausa .badge::before, html.pausa .vs-dot { animation: none; }
html.lite dialog::backdrop { backdrop-filter: none; }
html.lite .glass::before { display: none; }
html.pausa *, html.pausa *::before, html.pausa *::after { animation-play-state: paused !important; }

/* ---- olhinho das telas: oculta a prévia (poupa PC); a transmissão não é afetada ---- */
.tile .eye { position: absolute; right: 10px; top: 10px; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%; background: rgba(7,9,22,.72); border: 1px solid var(--linha); color: var(--espuma); opacity: 0; transition: opacity .2s, transform .25s var(--mola); z-index: 2; }
.tile:hover .eye, .tile.oculto .eye, .tile .eye:focus-visible { opacity: 1; }
.tile .eye:hover { transform: scale(1.12); }
.tile .off { position: absolute; inset: 0; display: none; place-content: center; gap: 4px; text-align: center; color: var(--suave); font-size: 13px; background: #060818; }
.tile .off b { color: var(--espuma); font-size: 14px; }
.tile.oculto .off { display: grid; }
.tile.oculto video { visibility: hidden; }

/* botão de silenciar só a transmissão (ao lado do olho) */
.tile .fs { right: 52px; }
.tile .smute { right: 94px; }
.tile .smute.on { opacity: 1; background: var(--rubi); color: #fff; }

/* ---- larguras ajustáveis: bordas que se arrastam ---- */
:root { --w-side: 284px; --w-mem: 236px; --w-chat: clamp(330px, 33%, 430px); }
#main-body { position: relative; }
.rz { position: absolute; z-index: 6; width: 12px; cursor: col-resize; touch-action: none; }
.rz::after { content: ""; position: absolute; left: 5px; top: 50%; width: 3px; height: 54px; margin-top: -27px; border-radius: 3px; background: var(--lavanda); opacity: 0; transition: opacity .2s, height .2s; }
.rz:hover::after, .rz.on::after { opacity: .8; height: 90px; }
.rz-side { top: 12px; bottom: 12px; left: calc(92px + var(--w-side)); }
.rz-mem { top: 12px; bottom: 12px; right: calc(12px + var(--w-mem)); }
.rz-chat { top: 0; bottom: 0; width: 10px; right: calc(var(--w-chat) - 5px); }
.rz-chat::after { left: 3px; }
.rz[hidden] { display: none; }
body.resizing { cursor: col-resize; user-select: none; }
body.resizing iframe, body.resizing video { pointer-events: none; }
@media (max-width: 1000px) { .rz-side, .rz-mem { display: none; } }

/* ---- anexos no chat ---- */
#btn-attach { width: 42px; height: 42px; flex: none; border-radius: 50%; }
#att-bar { display: flex; gap: 10px; margin: 0 16px 6px; padding: 8px; border-radius: 18px; background: rgba(0,0,0,.28); border: 1px solid var(--linha); align-items: center; animation: pop .3s var(--mola); }
#att-bar[hidden] { display: none; }
#att-bar .thumb { width: 52px; height: 52px; border-radius: 12px; background: var(--vidro-2) center / cover; display: grid; place-items: center; flex: none; }
#att-bar .info { flex: 1; min-width: 0; display: grid; gap: 4px; font-size: 13px; }
#att-bar .info b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#att-bar .info small { color: var(--suave); }
#att-bar .prog { height: 4px; border-radius: 4px; background: rgba(255,255,255,.12); overflow: hidden; }
#att-bar .prog i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--lavanda), var(--gelo)); transition: width .15s; }
#chatcol.drop { outline: 2px dashed var(--gelo); outline-offset: -8px; background: rgba(var(--gelo-rgb), .06); }
.msg .att-img { display: block; margin-top: 6px; max-width: min(380px, 100%); max-height: 320px; border-radius: 14px; border: 1px solid var(--linha); cursor: zoom-in; background: rgba(0,0,0,.25); }
.msg .att-file { display: inline-flex; align-items: center; gap: 12px; margin-top: 6px; padding: 10px 14px; max-width: min(380px, 100%); border-radius: 14px; background: rgba(0,0,0,.25); border: 1px solid var(--linha); color: var(--espuma); text-decoration: none; transition: background .2s, transform .25s var(--mola); }
.msg .att-file:hover { background: rgba(255,255,255,.08); transform: translateY(-1px); }
.msg .att-file .ic { font-size: 26px; color: var(--gelo); }
.msg .att-file span { display: grid; min-width: 0; }
.msg .att-file b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.msg .att-file small { color: var(--suave); font-size: 12px; }
dialog.lightbox { width: auto; max-width: 94vw; padding: 14px; background: rgba(5,6,14,.96); }
dialog.lightbox img { display: block; max-width: 90vw; max-height: 76vh; margin: 0 auto; border-radius: 14px; }
.btn-link { display: inline-flex; align-items: center; gap: 8px; padding: 11px 16px; border-radius: 14px; background: var(--vidro-2); color: var(--espuma); text-decoration: none; }

/* ---- amigos ---- */
#req-list li, #friend-list li { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: 14px; cursor: pointer; transition: background .2s; }
#friend-list li:hover, #req-list li:hover { background: var(--vidro); }
#req-list li { cursor: default; background: rgba(var(--lavanda-rgb), .08); margin-bottom: 3px; }
#req-list .nm, #friend-list .nm { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#req-list small { color: var(--suave); }
#friend-list .del { display: none; }
#friend-list li:hover .del { display: grid; }
.mini-btn { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 50%; background: var(--vidro-2); color: var(--espuma); }
.mini-btn:hover { background: var(--lavanda); color: var(--tinta); }
.mini-btn.no:hover { background: var(--rubi); color: #fff; }
#friend-hint[hidden] { display: none; }
.rail-btn.has-img { color: transparent; }

#room-controls { flex-wrap: wrap; row-gap: 8px; }

.tile:fullscreen { border-radius: 0; border: 0; aspect-ratio: auto; width: 100vw; height: 100vh; background: #000; }
.tile:fullscreen .eye { opacity: .85; }

/* ---- atalhos de teclado ---- */
.hk-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--linha); }
.hk { min-width: 190px; padding: 9px 14px; border-radius: 12px; background: var(--vidro-2); font-weight: 600; font-size: 13px; text-align: center; }
.hk.ouvindo { background: linear-gradient(120deg, var(--lavanda), var(--gelo)); color: var(--tinta); animation: pulsa 1.2s ease-in-out infinite; }
.hk.vazio { color: var(--suave); font-weight: 500; }

/* ---- volume de uma pessoa (clique direito ou botão no assento) ---- */
#vol-pop { position: fixed; z-index: 40; width: 250px; padding: 14px 16px; display: grid; gap: 8px; border-radius: 20px; animation: pop .25s var(--mola); }
#vol-pop[hidden] { display: none; }
#vol-pop b { font: 700 15px var(--titulo); }
#vol-pop input[type=range] { width: 100%; }
#vol-pop #vp-out { color: var(--suave); font-size: 13px; }
.seat .vbtn { position: absolute; top: 0; left: calc(50% + 22px); width: 26px; height: 26px; display: grid; place-items: center; border-radius: 50%; background: rgba(7,9,22,.82); border: 1px solid var(--linha); color: var(--espuma); opacity: 0; transition: opacity .2s; z-index: 2; }
.seat:hover .vbtn, .seat .vbtn:focus-visible { opacity: 1; }

/* 5 abas cabem sem rolagem */
dialog.wide { width: min(660px, 94vw); }
.tabs-h { overflow: hidden; }
.tabs-h button { padding: 9px 4px; font-size: 13px; gap: 5px; white-space: nowrap; min-width: 0; }

.msg .link { color: var(--gelo); text-decoration: underline; text-underline-offset: 2px; word-break: break-all; }
.msg .link:hover { color: var(--espuma); }

/* ---- novos temas ---- */
html[data-tema="oceano"] { --lavanda-rgb: 80,170,255; --gelo-rgb: 60,230,210; --aur1: 20,100,200; --aur2: 10,160,160; --aur3: 60,120,255; --fundo-glow: #0b1a2e; }
html[data-tema="sakura"] { --lavanda-rgb: 255,150,200; --gelo-rgb: 255,190,150; --aur1: 220,60,140; --aur2: 160,60,200; --aur3: 255,120,120; --fundo-glow: #2a0d1f; }
html[data-tema="grafite"] { --lavanda-rgb: 190,200,215; --gelo-rgb: 120,150,185; --aur1: 70,80,100; --aur2: 50,60,80; --aur3: 90,100,120; --fundo-glow: #12151c; }
html[data-tema="rubi"] { --lavanda-rgb: 255,80,100; --gelo-rgb: 255,140,120; --aur1: 200,20,50; --aur2: 120,10,40; --aur3: 255,60,60; --fundo-glow: #2a0a12; }

/* ---- chat: tamanho do texto e modo compacto ---- */
.msg .body { font-size: var(--chat-fs, 15.5px); }
html.compact .msg { padding-top: 2px; padding-bottom: 2px; gap: 10px; }
html.compact .msg .avatar { width: 30px; height: 30px; }
html.compact .msg .text { margin-top: 0; }

/* ---- status (online, ausente, não perturbe) ---- */
.dot.idle { background: #ffc94d; box-shadow: 0 0 8px rgba(255,201,77,.6); }
.dot.dnd { background: var(--rubi); box-shadow: 0 0 8px rgba(var(--rubi-rgb), .6); }
.mrow.pres-idle .avatar::after { background: #ffc94d !important; }
.mrow.pres-dnd .avatar::after { background: var(--rubi) !important; }
.mrow .st.game { color: var(--menta); }
#me-name { text-align: left; font-weight: 600; padding: 2px 4px; border-radius: 8px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#me-name:hover { background: var(--vidro); }
.avatar-btn { position: relative; }
.avatar-btn::after { content: ""; position: absolute; right: -1px; bottom: -1px; width: 11px; height: 11px; border-radius: 50%; border: 2px solid #0d0f1c; background: var(--menta); }
.avatar-btn[data-pres="idle"]::after { background: #ffc94d; }
.avatar-btn[data-pres="dnd"]::after { background: var(--rubi); }
.avatar-btn[data-pres="invisible"]::after { background: #4a4f6b; }
#presence-pop { position: fixed; z-index: 40; width: 250px; padding: 8px; display: grid; gap: 2px; border-radius: 18px; animation: pop .25s var(--mola); }
#presence-pop[hidden] { display: none; }
#presence-pop button { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 12px; text-align: left; font-weight: 600; }
#presence-pop button:hover { background: var(--vidro-2); }
#presence-pop small { color: var(--suave); font-weight: 400; font-size: 11px; margin-left: auto; }
#presence-pop .dot { display: inline-block; }

/* ---- transmissão: assistir sob demanda, volume e clipe ---- */
.tile .off span { display: block; }
.tile .tvol { position: absolute; right: 10px; bottom: 12px; width: 110px; opacity: 0; transition: opacity .2s; z-index: 2; accent-color: var(--lavanda); }
.tile:hover .tvol, .tile .tvol:focus-visible { opacity: 1; }
.tile .clipb { right: 136px; display: none; }
html.clips-on .tile:not([data-local]) .clipb { display: grid; }
.tile .off { cursor: pointer; }
.tile .off b { font-size: 15px; }

/* ---- configurações do servidor ---- */
#dlg-roles .tabs-h { margin-bottom: 12px; }
#dlg-roles section[data-spane] { animation: sobe-leve .3s var(--suave-out) both; }
#dlg-roles section[hidden] { display: none; }
#srv-channels, #srv-members { display: grid; gap: 6px; margin-bottom: 8px; }
.srow { display: flex; align-items: center; gap: 10px; padding: 6px 8px; border-radius: 14px; background: var(--vidro); }
.srow input { flex: 1; min-width: 0; padding: 7px 10px; }
.srow .nm { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; }
.srow .chips { display: flex; gap: 4px; flex-wrap: wrap; }
.srow .chip { padding: 1px 8px; border-radius: 999px; font-size: 11px; background: var(--vidro-2); }
#srv-msearch { margin-bottom: 8px; }
.inline { display: flex; gap: 8px; align-items: center; }
.inline input[type=text], .inline input:not([type]) { flex: 1; min-width: 0; }

/* ajustes: mini-botões dentro de diálogos e seletor de cor */
dialog .mini-btn { padding: 0 !important; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; }
dialog .mini-btn .ic { vertical-align: 0; }
input[type=color] { flex: none; width: 56px; height: 36px; padding: 2px; border-radius: 10px; border: 1px solid var(--linha); background: var(--vidro); cursor: pointer; }

/* ---- bot de música ---- */
#music-panel { margin: 8px 16px 0; padding: 12px 14px; border-radius: 20px; background: rgba(0,0,0,.25); border: 1px solid var(--linha); animation: pop .3s var(--mola); }
#music-panel[hidden] { display: none; }
.mu-head { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.mu-head b { font: 700 14px var(--titulo); }
.mu-head span { flex: 1; min-width: 0; text-align: right; color: var(--suave); font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#mu-form { display: flex; gap: 8px; }
#mu-form input { flex: 1; min-width: 0; }
.mu-ctl { display: flex; align-items: center; gap: 8px; margin: 8px 0 4px; }
.mu-ctl label { display: flex; align-items: center; gap: 6px; flex: 1; color: var(--suave); }
.mu-ctl input[type=range] { flex: 1; }
#mu-queue { display: grid; gap: 4px; margin: 6px 0; font-size: 13px; max-height: 120px; overflow-y: auto; }
#mu-queue li { display: flex; gap: 8px; padding: 5px 8px; border-radius: 10px; background: var(--vidro); }
#mu-queue li span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#mu-queue li small { color: var(--suave); }

/* ---- a "Música" como participante da roda ---- */
.avatar.bot { background: linear-gradient(145deg, #1ed760, #0f7a38) !important; color: #fff; font-size: 1.1em; }
.seat.bot .avatar { box-shadow: 0 0 0 2px rgba(30,215,96,.5); }
#btn-music.live { color: #1ed760; }

/* ---- cartão "tocando agora" (painel da direita) ---- */
#members { display: flex; flex-direction: column; }
.np { margin: 2px 6px 12px; padding: 12px; border-radius: 18px; background: linear-gradient(160deg, rgba(30,215,96,.16), rgba(255,255,255,.03)); border: 1px solid rgba(30,215,96,.28); display: grid; gap: 9px; animation: pop .3s var(--mola); flex: none; }
.np[hidden] { display: none; }
#chatcol > .np { margin: 8px 16px 0; }
.np-top { display: flex; align-items: center; gap: 7px; }
.np-top b { font: 700 13px var(--titulo); }
.np-top span { flex: 1; min-width: 0; text-align: right; color: var(--suave); font-size: 11.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.np-main { display: flex; gap: 11px; align-items: center; }
.np-art { width: 58px; height: 58px; flex: none; border-radius: 12px; background: #11142a center / cover; display: grid; place-items: center; font-size: 24px; color: rgba(255,255,255,.55); }
.np-art:not(.vazio) .ic { display: none; }
.np-art.tocando { box-shadow: 0 0 0 2px rgba(30,215,96,.6), 0 8px 22px -8px rgba(30,215,96,.7); }
.np-info { display: grid; min-width: 0; gap: 2px; }
.np-info b { font-size: 14px; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.np-info small { color: var(--suave); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.np-prog { display: flex; align-items: center; gap: 7px; font-size: 11px; color: var(--suave); }
.np-bar { flex: 1; height: 4px; border-radius: 4px; background: rgba(255,255,255,.14); overflow: hidden; }
.np-bar i { display: block; height: 100%; width: 0; background: #1ed760; border-radius: 4px; }
.np-ctl { display: flex; align-items: center; gap: 6px; }
.np-ctl[hidden] { display: none; }
.np-ctl input[type=range] { flex: 1; min-width: 0; accent-color: #1ed760; }
.np-ctl #np-vol-out { width: 34px; text-align: right; font-size: 11px; color: var(--suave); }
.np .mini-btn { padding: 0 !important; width: 28px; height: 28px; display: grid; place-items: center; flex: none; }
.np-all { padding: 7px 10px; border-radius: 12px; background: var(--vidro-2); font-size: 12.5px; font-weight: 600; }
.np-all[hidden] { display: none; }
#np-queue { display: grid; gap: 3px; font-size: 12.5px; max-height: 110px; overflow-y: auto; }
#np-queue:empty { display: none; }
#np-queue li { display: flex; gap: 8px; padding: 4px 8px; border-radius: 9px; background: var(--vidro); }
#np-queue li span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#np-queue li small { color: var(--suave); }
#np-form { display: flex; gap: 6px; }
#np-form input { flex: 1; min-width: 0; padding: 8px 10px; font-size: 12.5px; }
#np-form .primary { width: 34px; padding: 0; border-radius: 10px; }

#np-loop.on { background: #1ed760; color: #04210e; }
#bot-icon-box[hidden] { display: none; }
.avatar.bot.has-img { color: transparent; }

/* ---- respostas, reações, menções, busca ---- */
.msg .quote { display: flex; align-items: center; gap: 6px; margin-bottom: 3px; padding: 3px 10px; border-left: 3px solid var(--lavanda); border-radius: 0 10px 10px 0; background: rgba(255,255,255,.05); color: var(--suave); font-size: 12.5px; cursor: pointer; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.msg .quote b { color: var(--espuma); }
.msg .quote:hover { background: rgba(255,255,255,.09); }
.reacts { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 5px; }
.react { padding: 2px 9px; border-radius: 999px; background: var(--vidro-2); border: 1px solid transparent; font-size: 13px; transition: transform .2s var(--mola), background .2s; }
.react:hover { transform: translateY(-1px); background: rgba(255,255,255,.18); }
.react.mine { border-color: var(--lavanda); background: rgba(var(--lavanda-rgb), .2); }
#emoji-pop { position: fixed; z-index: 41; display: flex; gap: 2px; padding: 6px; border-radius: 16px; animation: pop .2s var(--mola); }
#emoji-pop[hidden] { display: none; }
#emoji-pop button { width: 34px; height: 34px; font-size: 19px; border-radius: 10px; transition: transform .15s var(--mola), background .15s; }
#emoji-pop button:hover { background: var(--vidro-2); transform: scale(1.2); }
#reply-bar { display: flex; align-items: center; gap: 8px; margin: 0 16px 6px; padding: 6px 8px 6px 12px; border-radius: 14px; background: rgba(0,0,0,.28); border: 1px solid var(--linha); color: var(--suave); font-size: 13px; animation: pop .25s var(--mola); }
#reply-bar[hidden] { display: none; }
#reply-bar .rtxt { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mention { padding: 0 4px; border-radius: 6px; background: rgba(var(--lavanda-rgb), .22); color: var(--espuma); font-weight: 600; }
.mention.me { background: rgba(255,196,86,.28); color: #ffe3a3; }
.msg.mentioned { background: rgba(255,196,86,.09); border-left-color: #ffc456; }
.msg.flash { animation: flash 1.5s ease-out; }
@keyframes flash { 0%, 40% { background: rgba(var(--gelo-rgb), .28); } }
#sr-list { display: grid; gap: 6px; margin: 12px 0; max-height: 52vh; overflow-y: auto; color: var(--suave); }
#sr-list .hit { padding: 8px 12px; border-radius: 12px; background: var(--vidro); cursor: pointer; color: var(--espuma); font-size: 14px; }
#sr-list .hit:hover { background: var(--vidro-2); }
#sr-list .hit small { display: block; color: var(--suave); font-size: 11.5px; margin-bottom: 2px; }

/* ---- digitando, fixadas, GIFs ---- */
#typing { margin: 0 22px 4px; font-size: 12.5px; color: var(--suave); min-height: 1em; animation: pop .2s var(--mola); }
#typing[hidden] { display: none; }
.msg.pinned { border-left-color: #ffc456; }
.msg.pinned .body > div:first-child b::after { content: " 📌"; font-size: 11px; }
#pins-list { display: grid; gap: 6px; margin: 12px 0; max-height: 52vh; overflow-y: auto; color: var(--suave); }
#pins-list .hit { padding: 8px 12px; border-radius: 12px; background: var(--vidro); cursor: pointer; color: var(--espuma); font-size: 14px; }
#pins-list .hit:hover { background: var(--vidro-2); }
#pins-list .hit small { display: block; color: var(--suave); font-size: 11.5px; margin-bottom: 2px; }
.gifb { width: auto !important; padding: 0 11px !important; font: 800 12px var(--titulo); letter-spacing: .04em; }
#gif-pop { position: fixed; z-index: 41; width: 340px; padding: 10px; display: grid; gap: 8px; border-radius: 18px; animation: pop .2s var(--mola); }
#gif-pop[hidden] { display: none; }
#gif-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; max-height: 300px; overflow-y: auto; }
#gif-grid img { width: 100%; height: 96px; object-fit: cover; border-radius: 10px; cursor: pointer; background: rgba(0,0,0,.3); transition: transform .15s var(--mola); }
#gif-grid img:hover { transform: scale(1.03); }

/* barra de progresso arrastável da música */
.np-seek { flex: 1; min-width: 0; -webkit-appearance: none; appearance: none; height: 14px; background: transparent; cursor: pointer; --p: 0%; }
.np-seek::-webkit-slider-runnable-track { height: 4px; border-radius: 4px; background: linear-gradient(90deg, #1ed760 var(--p), rgba(255,255,255,.14) var(--p)); }
.np-seek::-webkit-slider-thumb { -webkit-appearance: none; width: 12px; height: 12px; margin-top: -4px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 2px rgba(30,215,96,.55); opacity: 0; transition: opacity .15s; }
.np-seek:hover::-webkit-slider-thumb, .np-seek:active::-webkit-slider-thumb, .np-seek:focus-visible::-webkit-slider-thumb { opacity: 1; }
.np-seek:disabled { cursor: default; opacity: .6; }
