/* GattoMusic 2.0 / Build 10.02 — Sala canônica limpa e estável.
   A nova árvore usa somente classes gatto-room-*; CSS histórico de wrappers não
   participa da geometria desta superfície. */

:root{
  --gatto-room-bg:#07101a;
  --gatto-room-panel:#0a1420;
  --gatto-room-card:#0d1724;
  --gatto-room-line:rgba(118,153,190,.22);
  --gatto-room-line-strong:rgba(137,79,255,.58);
  --gatto-room-text:#f5f7fb;
  --gatto-room-muted:#8f9bae;
  --gatto-room-accent:#8b32ff;
  --gatto-room-accent-2:#b448ff;
  --gatto-room-danger:#ff5364;
  --gatto-room-font:Verdana, Geneva, sans-serif;
  --gatto-room-font-size:clamp(12px,.78vw,14px);
}

.chat-room-sidepanel-v972.gatto-room-shell{
  position:fixed!important;
  z-index:520!important;
  top:76px!important;
  right:12px!important;
  bottom:12px!important;
  width:clamp(540px,48vw,900px)!important;
  height:auto!important;
  max-height:none!important;
  display:none!important;
  grid-template-columns:minmax(0,1fr)!important;
  grid-template-rows:auto auto auto minmax(0,1fr) auto!important;
  gap:10px!important;
  padding:12px!important;
  margin:0!important;
  overflow:hidden!important;
  box-sizing:border-box!important;
  border:1px solid rgba(89,150,197,.28)!important;
  border-radius:17px!important;
  background:
    radial-gradient(circle at 48% -10%,rgba(112,32,204,.11),transparent 34%),
    linear-gradient(180deg,#07111c 0%,#06101a 100%)!important;
  color:var(--gatto-room-text)!important;
  box-shadow:-20px 24px 64px rgba(0,0,0,.48)!important;
  isolation:isolate!important;
  min-height:0!important;
  font-family:var(--gatto-room-font)!important;
  font-size:var(--gatto-room-font-size)!important;
}
.chat-room-sidepanel-v972.gatto-room-shell.is-open{display:grid!important;visibility:visible!important;pointer-events:auto!important}
.chat-room-sidepanel-v972.gatto-room-shell[aria-hidden="true"]{display:none!important;visibility:hidden!important;pointer-events:none!important}
body.chat-view-active.chat-v972-room-open .chat-workspace-panel{
  width:calc(100% - clamp(540px,48vw,900px) - 16px)!important;
  margin-right:auto!important;
}

.gatto-room-header{
  position:relative;
  min-width:0;
  min-height:52px;
  display:grid;
  grid-template-columns:42px minmax(0,1fr) auto;
  align-items:center;
  gap:10px;
  padding:6px 8px;
  border:1px solid rgba(94,128,163,.13);
  border-radius:14px;
  background:linear-gradient(180deg,rgba(15,27,42,.96),rgba(9,19,31,.96));
}
.gatto-room-menu-button{
  width:38px;height:38px;display:grid;place-items:center;border:0;border-radius:10px;
  background:transparent;color:var(--gatto-room-text);font-size:1.25rem;cursor:pointer;
}
.gatto-room-menu-button:hover{background:rgba(255,255,255,.06)}
.gatto-room-shell button,.gatto-room-shell select,.gatto-room-shell textarea,.gatto-room-shell input{font-family:var(--gatto-room-font)!important}
.gatto-room-brand{display:grid;place-items:center;min-width:0;line-height:1.1}
.gatto-room-brand-title{display:flex;align-items:center;gap:8px;font-size:clamp(15px,1vw,18px);white-space:nowrap}
.gatto-room-brand-title strong{font-size:inherit;font-weight:900;letter-spacing:-.02em}
.gatto-room-brand-title strong>span{color:var(--gatto-room-accent-2)}
.gatto-room-cat{font-size:1.12rem;filter:saturate(1.35)}
.gatto-room-brand>small{max-width:100%;margin-top:2px;color:var(--gatto-room-muted);font-size:12px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.gatto-room-online{height:36px;display:flex;align-items:center;gap:8px;padding:0 11px;border-radius:13px;background:rgba(255,255,255,.035);color:#d9dee8;font-size:12px;white-space:nowrap}
.gatto-room-online-dot{width:8px;height:8px;border-radius:50%;background:#6cdf48;box-shadow:0 0 10px rgba(108,223,72,.34)}
.gatto-room-online>span:last-child{font-size:1rem}
.gatto-room-top-menu{
  position:absolute;top:48px;left:8px;z-index:80;width:min(270px,calc(100vw - 40px));display:grid;gap:5px;padding:8px;
  border:1px solid var(--gatto-room-line);border-radius:12px;background:#0c1724;box-shadow:0 18px 44px rgba(0,0,0,.46)
}
.gatto-room-top-menu[hidden]{display:none!important}
.gatto-room-top-menu .gatto-room-popover-action{justify-content:flex-start!important;width:100%}

.gatto-room-gallery{
  min-width:0;min-height:0;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px;
  align-items:stretch;align-content:start;overflow:hidden;
}
.gatto-room-gallery[data-count="0"]{min-height:132px}
.gatto-room-gallery[data-count="1"]{grid-template-columns:minmax(0,1fr)}
.gatto-room-gallery[data-count="1"]>.gatto-room-participant{width:min(100%,680px);justify-self:center}
.gatto-room-gallery[data-count="2"]{grid-template-columns:repeat(2,minmax(0,1fr))}
.gatto-room-gallery[data-count="3"]{grid-template-columns:repeat(2,minmax(0,1fr))}
.gatto-room-gallery[data-count="3"]>.gatto-room-participant:nth-child(3){grid-column:1/-1;width:calc(50% - 4px);justify-self:center}
.gatto-room-gallery[data-count="4"]{grid-template-columns:repeat(2,minmax(0,1fr))}
.gatto-room-gallery[data-count="5"],.gatto-room-gallery[data-count="6"]{grid-template-columns:repeat(3,minmax(0,1fr))}
.gatto-room-gallery[data-count="7"],.gatto-room-gallery[data-count="8"],.gatto-room-gallery[data-count="9"]{grid-template-columns:repeat(3,minmax(0,1fr))}

.gatto-room-participant{
  position:relative;min-width:0;min-height:118px;aspect-ratio:16/9;overflow:hidden;border:1px solid rgba(88,134,193,.58);
  border-radius:12px;background:#080d14;box-shadow:inset 0 0 0 1px rgba(0,0,0,.28);contain:layout paint;
}
.gatto-room-participant:nth-child(even){border-color:rgba(133,68,210,.62)}
.gatto-room-media{position:absolute;inset:0;overflow:hidden;background:radial-gradient(circle at 50% 25%,#16263a 0%,#080d14 72%)}
.gatto-room-video{position:absolute;inset:0;width:100%;height:100%;display:none;object-fit:cover;background:#080d14}
.gatto-room-participant.has-video .gatto-room-video{display:block}
.gatto-room-avatar{position:absolute;inset:0;display:grid;place-items:center;font-size:clamp(2.4rem,7vw,5rem);font-weight:900;color:rgba(255,255,255,.86);background:radial-gradient(circle at 45% 35%,rgba(121,41,205,.38),rgba(10,17,28,.94) 66%)}
.gatto-room-participant.has-video .gatto-room-avatar{display:none}
.gatto-room-name{
  position:absolute;right:8px;bottom:7px;z-index:4;max-width:calc(100% - 16px);display:flex;align-items:center;gap:6px;
  padding:4px 8px;border-radius:9px;background:rgba(5,8,13,.70);backdrop-filter:blur(6px);font-size:12px;line-height:1.2;color:#fff;
}
.gatto-room-name-text{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-weight:800}
.gatto-room-media-status{color:#9f43ff;font-size:11px;font-weight:900;letter-spacing:-1px}
.gatto-room-participant.mic-off .gatto-room-media-status{color:#aab1bd;opacity:.72}
.gatto-room-idle{grid-column:1/-1;min-height:132px;display:grid;place-items:center;align-content:center;gap:5px;border:1px dashed var(--gatto-room-line);border-radius:12px;color:var(--gatto-room-muted);text-align:center;background:rgba(255,255,255,.018)}
.gatto-room-idle>span{font-size:1.8rem}.gatto-room-idle>strong{color:var(--gatto-room-text)}.gatto-room-idle>p{margin:0;font-size:12px}

.gatto-room-gallery.is-preentry{grid-template-columns:minmax(0,1fr)!important;align-content:stretch;overflow:visible}
.gatto-room-preentry{
  grid-column:1/-1;min-width:0;min-height:190px;display:grid;grid-template-columns:minmax(0,1fr);place-items:center;align-content:center;gap:9px;
  padding:16px 18px;border:1px dashed rgba(118,153,190,.34);border-radius:13px;background:linear-gradient(180deg,rgba(15,27,42,.80),rgba(7,16,26,.76));text-align:center;color:var(--gatto-room-text)
}
.gatto-room-preentry-icon{font-size:2rem;line-height:1}
.gatto-room-preentry-title{font-size:clamp(17px,1.2vw,21px);font-weight:900}
.gatto-room-preentry-status,.gatto-room-preentry-question,.gatto-room-preentry-error{margin:0;line-height:1.45}
.gatto-room-preentry-status{color:var(--gatto-room-muted);font-size:clamp(12px,.82vw,14px)}
.gatto-room-preentry-question{font-size:clamp(13px,.9vw,15px);font-weight:800;color:#eef2f7}
.gatto-room-preentry-options{width:min(100%,560px);display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.gatto-room-preentry-toggle{
  min-height:44px;display:inline-flex;align-items:center;justify-content:center;gap:10px;
  border:1px solid rgba(117,137,165,.28);border-radius:11px;background:#0d1926;color:#d8dee8;
  padding:8px 12px;cursor:pointer;font:inherit;font-weight:800;line-height:1.2;text-align:center
}
.gatto-room-preentry-toggle-icon{display:inline-block!important;flex:0 0 1.18rem!important;width:1.18rem!important;height:1.18rem!important;margin:0!important;vertical-align:middle!important}
.gatto-room-preentry-toggle-label{display:inline-flex;align-items:center;min-height:1.18rem;margin:0;line-height:1.2}
.gatto-room-preentry-toggle:hover:not(:disabled){background:rgba(139,50,255,.12);border-color:rgba(139,50,255,.42)}
.gatto-room-preentry-toggle.is-on{border-color:rgba(139,50,255,.72);background:linear-gradient(180deg,rgba(117,38,214,.38),rgba(59,25,107,.34));color:#fff}
.gatto-room-preentry-toggle:disabled{opacity:.48;cursor:not-allowed}
.gatto-room-preentry-actions{width:min(100%,420px);display:grid;grid-template-columns:1fr 1.2fr;gap:8px}
.gatto-room-preentry-actions>.button{min-height:42px;font-size:13px;font-weight:900}
.gatto-room-preentry-enter{background:linear-gradient(135deg,#7f28e8,#9a24ff)!important;border-color:#a748ff!important}
.gatto-room-preentry-error{color:#ff8a97;font-size:12px;font-weight:700}

.gatto-room-controls-wrap{position:relative;z-index:22;display:grid;place-items:center;min-width:0}
.gatto-room-controls{display:flex;align-items:stretch;justify-content:center;gap:7px;min-width:0;max-width:100%;flex-wrap:wrap}
.gatto-room-controls[hidden]{display:none!important}.gatto-room-controls-wrap.is-preentry{min-height:0}
.gatto-room-control-split{display:grid;grid-template-columns:auto 24px;min-width:105px;border:1px solid rgba(117,137,165,.21);border-radius:12px;background:linear-gradient(180deg,rgba(18,29,44,.96),rgba(10,18,29,.96));overflow:hidden}
.gatto-room-control{
  min-width:82px;min-height:52px;display:grid;place-items:center;align-content:center;gap:3px;padding:6px 10px;border:1px solid rgba(117,137,165,.21);border-radius:12px;
  background:linear-gradient(180deg,rgba(18,29,44,.96),rgba(10,18,29,.96));color:#e9edf5;cursor:pointer;font:inherit;
}
.gatto-room-control-split>.gatto-room-control{min-width:80px;border:0;border-radius:0;background:transparent}
.gatto-room-control-menu{width:24px;border:0;border-left:1px solid rgba(117,137,165,.15);background:transparent;color:#b5bdc9;cursor:pointer;font-size:.72rem}
.gatto-room-control:hover,.gatto-room-control-menu:hover{background:rgba(139,50,255,.12)}
.gatto-room-control:disabled,.gatto-room-control-menu:disabled{opacity:.42;cursor:not-allowed}
.gatto-room-control-icon{font-size:1.18rem;line-height:1;color:#e5e9f0}.gatto-room-control-label{font-size:12px;white-space:nowrap}
.gatto-room-control.is-off .gatto-room-control-icon{color:var(--gatto-room-danger)}
.gatto-room-control.is-danger .gatto-room-control-icon{color:var(--gatto-room-danger)}
.gatto-room-control.is-primary{border-color:rgba(139,50,255,.65);background:linear-gradient(180deg,rgba(132,42,245,.78),rgba(91,25,181,.82))}

.gatto-room-popover{
  position:absolute;top:calc(100% + 7px);left:50%;transform:translateX(-50%);z-index:70;width:min(520px,calc(100vw - 54px));max-height:min(42dvh,330px);overflow:auto;
  display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;padding:10px;border:1px solid rgba(139,50,255,.38);border-radius:13px;background:#0b1623;box-shadow:0 20px 50px rgba(0,0,0,.48)
}
.gatto-room-popover[hidden]{display:none!important}
.gatto-room-field{display:grid;gap:4px;min-width:0;color:#dce2eb;font-size:12px;font-weight:800}
.gatto-room-field>select{width:100%;min-width:0;height:34px;border:1px solid var(--gatto-room-line);border-radius:8px;background:#101c2a;color:#f2f5fa;padding:0 8px}
.gatto-room-popover-row{display:flex;gap:6px;min-width:0;flex-wrap:wrap}.gatto-room-popover-action{min-height:34px!important;font-size:12px!important;flex:1 1 auto}.gatto-room-popover-action.danger{color:#ff9aa5!important}
.gatto-room-popover-note{grid-column:1/-1;margin:0;color:var(--gatto-room-muted);font-size:12px;line-height:1.4}.gatto-room-popover>.gatto-room-popover-action:last-child{grid-column:1/-1}

.gatto-room-messages{
  min-width:0;min-height:0;height:100%;max-height:100%;display:grid;grid-template-rows:auto minmax(0,1fr);overflow:hidden;border:1px solid var(--gatto-room-line);border-radius:12px;background:rgba(7,14,23,.62);contain:size layout paint
}
.gatto-room-messages-title{min-height:34px;display:flex;align-items:center;gap:8px;padding:0 11px;border-bottom:1px solid rgba(117,137,165,.13);font-size:13px}.gatto-room-messages-title>span{color:var(--gatto-room-accent-2)}
.gatto-room-message-list{min-width:0;min-height:0;height:100%;max-height:100%;overflow-y:auto;overscroll-behavior:contain;scrollbar-gutter:stable;display:grid;align-content:start;gap:7px;padding:9px 11px}
.gatto-room-message{display:grid;grid-template-columns:32px minmax(0,1fr);gap:8px;align-items:start;min-width:0}
.gatto-room-message-avatar{width:30px;height:30px;display:grid;place-items:center;border-radius:50%;background:linear-gradient(145deg,#45228b,#8a2ae6);color:white;font-size:12px;font-weight:900}
.gatto-room-message-body{min-width:0}.gatto-room-message-head{display:flex;align-items:baseline;gap:8px;min-width:0}.gatto-room-message-sender{color:#a447ff;font-size:12px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.gatto-room-message.is-own .gatto-room-message-sender{color:#c783ff}.gatto-room-message-time{color:#7f8a9b;font-size:11px}.gatto-room-message-text{margin:2px 0 0;color:#d7dce5;font-size:13px;line-height:1.4;white-space:pre-wrap;overflow-wrap:anywhere}.gatto-room-message-empty{place-self:center;color:var(--gatto-room-muted);font-size:12px;padding:18px}

.gatto-room-composer{min-width:0;display:grid;grid-template-columns:minmax(0,1fr) 118px;gap:8px;padding:7px 8px;border:1px solid var(--gatto-room-line);border-radius:12px;background:rgba(9,17,28,.92)}
.gatto-room-composer textarea{width:100%;height:42px;min-height:42px;max-height:42px;resize:none;box-sizing:border-box;border:1px solid rgba(117,137,165,.28);border-radius:9px;padding:10px 11px;background:#09131f;color:#eef2f7;outline:none;font:inherit;font-size:13px}
.gatto-room-composer textarea:focus{border-color:rgba(139,50,255,.55);box-shadow:0 0 0 2px rgba(139,50,255,.10)}
.gatto-room-send{height:42px!important;min-height:42px!important;border-radius:9px!important;background:linear-gradient(135deg,#7f28e8,#9a24ff)!important;border-color:#a748ff!important;font-size:13px!important;font-weight:900!important}

.gatto-room-detached-host .chat-room-sidepanel-v972.gatto-room-shell,
.gatto-room-fullscreen-host .chat-room-sidepanel-v972.gatto-room-shell,
.chat-room-sidepanel-v972.gatto-room-shell:fullscreen,
.chat-room-sidepanel-v972.gatto-room-shell:-webkit-full-screen{
  inset:8px!important;width:auto!important;height:auto!important;max-width:none!important;top:8px!important;right:8px!important;bottom:8px!important;left:8px!important;display:grid!important;border-radius:12px!important;padding:12px!important;transform:none!important;
}
.gatto-room-fullscreen-host .gatto-room-video,
.chat-room-sidepanel-v972.gatto-room-shell:fullscreen .gatto-room-video,
.chat-room-sidepanel-v972.gatto-room-shell:-webkit-full-screen .gatto-room-video{object-fit:contain!important;object-position:center center!important;transform:none!important}

/* Build 9.99: em fullscreen a Sala é uma superfície exclusiva de câmeras +
   controles. Mensagens continuam sincronizando em memória, mas não ocupam DOM
   visual nem faixa de grid até a saída do fullscreen. */
.gatto-room-fullscreen-host .chat-room-sidepanel-v972.gatto-room-shell,
.chat-room-sidepanel-v972.gatto-room-shell:fullscreen,
.chat-room-sidepanel-v972.gatto-room-shell:-webkit-full-screen{
  grid-template-rows:minmax(0,1fr) auto!important;
}
.gatto-room-fullscreen-host .gatto-room-header,
.gatto-room-fullscreen-host .gatto-room-messages,
.gatto-room-fullscreen-host .gatto-room-composer,
.chat-room-sidepanel-v972.gatto-room-shell:fullscreen .gatto-room-header,
.chat-room-sidepanel-v972.gatto-room-shell:fullscreen .gatto-room-messages,
.chat-room-sidepanel-v972.gatto-room-shell:fullscreen .gatto-room-composer,
.chat-room-sidepanel-v972.gatto-room-shell:-webkit-full-screen .gatto-room-header,
.chat-room-sidepanel-v972.gatto-room-shell:-webkit-full-screen .gatto-room-messages,
.chat-room-sidepanel-v972.gatto-room-shell:-webkit-full-screen .gatto-room-composer{display:none!important}
.gatto-room-fullscreen-host .gatto-room-gallery,
.chat-room-sidepanel-v972.gatto-room-shell:fullscreen .gatto-room-gallery,
.chat-room-sidepanel-v972.gatto-room-shell:-webkit-full-screen .gatto-room-gallery{
  min-height:0!important;height:100%!important;align-content:center!important;align-items:center!important;overflow:hidden!important;
}
.gatto-room-fullscreen-host .gatto-room-gallery[data-count="3"],
.chat-room-sidepanel-v972.gatto-room-shell:fullscreen .gatto-room-gallery[data-count="3"],
.chat-room-sidepanel-v972.gatto-room-shell:-webkit-full-screen .gatto-room-gallery[data-count="3"]{grid-template-columns:repeat(3,minmax(0,1fr))!important}
.gatto-room-fullscreen-host .gatto-room-gallery[data-count="3"]>.gatto-room-participant:nth-child(3),
.chat-room-sidepanel-v972.gatto-room-shell:fullscreen .gatto-room-gallery[data-count="3"]>.gatto-room-participant:nth-child(3),
.chat-room-sidepanel-v972.gatto-room-shell:-webkit-full-screen .gatto-room-gallery[data-count="3"]>.gatto-room-participant:nth-child(3){grid-column:auto!important;width:100%!important;justify-self:stretch!important}
.gatto-room-fullscreen-host .gatto-room-gallery[data-count="4"],
.chat-room-sidepanel-v972.gatto-room-shell:fullscreen .gatto-room-gallery[data-count="4"],
.chat-room-sidepanel-v972.gatto-room-shell:-webkit-full-screen .gatto-room-gallery[data-count="4"]{grid-template-columns:repeat(4,minmax(0,1fr))!important}
.gatto-room-fullscreen-host .gatto-room-gallery[data-count="7"],
.gatto-room-fullscreen-host .gatto-room-gallery[data-count="8"],
.gatto-room-fullscreen-host .gatto-room-gallery[data-count="9"],
.chat-room-sidepanel-v972.gatto-room-shell:fullscreen .gatto-room-gallery[data-count="7"],
.chat-room-sidepanel-v972.gatto-room-shell:fullscreen .gatto-room-gallery[data-count="8"],
.chat-room-sidepanel-v972.gatto-room-shell:fullscreen .gatto-room-gallery[data-count="9"],
.chat-room-sidepanel-v972.gatto-room-shell:-webkit-full-screen .gatto-room-gallery[data-count="7"],
.chat-room-sidepanel-v972.gatto-room-shell:-webkit-full-screen .gatto-room-gallery[data-count="8"],
.chat-room-sidepanel-v972.gatto-room-shell:-webkit-full-screen .gatto-room-gallery[data-count="9"]{grid-template-columns:repeat(4,minmax(0,1fr))!important}
.gatto-room-detached-host,.gatto-room-fullscreen-host{margin:0;background:#040a11;overflow:hidden}

@media(max-width:1120px){
  .chat-room-sidepanel-v972.gatto-room-shell{width:clamp(500px,52vw,760px)!important}
  body.chat-view-active.chat-v972-room-open .chat-workspace-panel{width:calc(100% - clamp(500px,52vw,760px) - 14px)!important}
  .gatto-room-control{min-width:74px}.gatto-room-control-split{min-width:96px}
}
@media(max-width:820px){
  body.chat-view-active.chat-v972-room-open .chat-workspace-panel{width:100%!important}
  .chat-room-sidepanel-v972.gatto-room-shell{inset:66px 7px 7px 7px!important;width:auto!important;top:66px!important;right:7px!important;bottom:7px!important;left:7px!important}
  .gatto-room-gallery[data-count="5"],.gatto-room-gallery[data-count="6"],.gatto-room-gallery[data-count="7"],.gatto-room-gallery[data-count="8"],.gatto-room-gallery[data-count="9"]{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:560px){
  .chat-room-sidepanel-v972.gatto-room-shell{inset:62px 3px 3px 3px!important;top:62px!important;right:3px!important;bottom:3px!important;left:3px!important;padding:7px!important;gap:6px!important;border-radius:10px!important}
  .gatto-room-header{grid-template-columns:38px minmax(0,1fr) auto;padding:4px 5px;min-height:46px}.gatto-room-online{padding:0 8px}.gatto-room-online>span:last-child{display:none}
  .gatto-room-brand-title{font-size:.9rem}.gatto-room-brand-title strong{font-size:.9rem}
  .gatto-room-gallery{gap:4px}.gatto-room-participant{min-height:94px;border-radius:9px}.gatto-room-name{right:5px;bottom:5px;padding:3px 6px;font-size:11px}
  .gatto-room-control{min-width:58px;min-height:45px;padding:4px 6px}.gatto-room-control-split{min-width:83px;grid-template-columns:auto 21px}.gatto-room-control-label{font-size:11px}.gatto-room-control-icon{font-size:1rem}.gatto-room-control-menu{width:21px}
  .gatto-room-popover{grid-template-columns:minmax(0,1fr);width:calc(100vw - 28px);max-height:44dvh;padding:8px}.gatto-room-popover>.gatto-room-popover-action:last-child{grid-column:auto}
  .gatto-room-preentry{min-height:170px;padding:11px 9px;gap:7px}.gatto-room-preentry-options,.gatto-room-preentry-actions{grid-template-columns:minmax(0,1fr);width:100%}.gatto-room-preentry-toggle,.gatto-room-preentry-actions>.button{min-height:38px}
  .gatto-room-composer{grid-template-columns:minmax(0,1fr) 84px;padding:5px}.gatto-room-send{padding-inline:7px!important}
}
@media(max-height:700px){
  .chat-room-sidepanel-v972.gatto-room-shell{gap:6px!important;padding:8px!important}
  .gatto-room-header{min-height:44px}.gatto-room-participant{min-height:86px}.gatto-room-control{min-height:42px}.gatto-room-composer textarea,.gatto-room-send{height:38px!important;min-height:38px!important;max-height:38px!important}
  .gatto-room-popover{max-height:38dvh}
}

body.light .chat-room-sidepanel-v972.gatto-room-shell{background:#eef3f8!important;color:#15202b!important;border-color:rgba(53,93,126,.25)!important}
body.light .gatto-room-header,body.light .gatto-room-controls-wrap,body.light .gatto-room-messages,body.light .gatto-room-composer{color:#17202b}


/* Build 10.00: estado explícito de fullscreen.
   O atributo é aplicado por room_window.js ao painel que realmente entrou em
   fullscreen. Assim a remoção de mensagens não depende só de :fullscreen e
   continua correta em Firefox/Chromium e após qualquer render da Sala. */
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-fullscreen="1"],
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-fullscreen{
  grid-template-rows:minmax(0,1fr) auto!important;
}
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-fullscreen="1"]>.gatto-room-header,
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-fullscreen="1"]>.gatto-room-messages,
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-fullscreen="1"]>.gatto-room-composer,
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-fullscreen>.gatto-room-header,
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-fullscreen>.gatto-room-messages,
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-fullscreen>.gatto-room-composer,
.gatto-room-shell [data-gatto-room-fullscreen-hidden="1"]{
  display:none!important;
  visibility:hidden!important;
  pointer-events:none!important;
  min-height:0!important;
  height:0!important;
  max-height:0!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  overflow:hidden!important;
}
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-fullscreen="1"]>.gatto-room-gallery,
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-fullscreen>.gatto-room-gallery{
  min-height:0!important;
  height:100%!important;
  max-height:100%!important;
  align-content:center!important;
  align-items:center!important;
  justify-content:center!important;
  overflow:hidden!important;
}
/* Não altera o card: somente o conteúdo de vídeo usa todo o retângulo já
   existente e mantém a imagem inteira no centro, inclusive fontes 4:3. */
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-fullscreen="1"] .gatto-room-media,
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-fullscreen .gatto-room-media{
  display:grid!important;
  place-items:center!important;
  overflow:hidden!important;
}
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-fullscreen="1"] .gatto-room-video,
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-fullscreen .gatto-room-video{
  inset:0!important;
  width:100%!important;
  height:100%!important;
  max-width:100%!important;
  max-height:100%!important;
  margin:auto!important;
  object-fit:contain!important;
  object-position:50% 50%!important;
  transform:none!important;
  transform-origin:center center!important;
}

/* Build 10.01: popovers dos controles abrem acima da barra quando o estado
   real de fullscreen está ativo. A geometria dos cards/botões não é alterada;
   left/max-height são refinados pelo controlador para respeitar a viewport. */
.gatto-room-popover[data-placement="above"]{
  top:auto!important;
  bottom:calc(100% + 7px)!important;
  transform:translateX(-50%)!important;
  overscroll-behavior:contain;
  scrollbar-gutter:stable;
}
.gatto-room-popover[data-placement="below"]{
  top:calc(100% + 7px);
  bottom:auto;
}
.gatto-room-controls-wrap.has-open-popover{z-index:90}



/* Build 10.02: fullscreen e "Destacar Sala" compartilham a mesma superfície
   de apresentação. O conteúdo de mensagens continua sendo processado, mas
   header/mensagens/composer não ocupam a janela destacada. */
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-detached="1"],
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-detached{
  grid-template-rows:minmax(0,1fr) auto!important;
}
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-detached="1"]>.gatto-room-header,
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-detached="1"]>.gatto-room-messages,
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-detached="1"]>.gatto-room-composer,
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-detached>.gatto-room-header,
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-detached>.gatto-room-messages,
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-detached>.gatto-room-composer,
.gatto-room-shell [data-gatto-room-detached-hidden="1"]{
  display:none!important;
  visibility:hidden!important;
  pointer-events:none!important;
  min-height:0!important;
  height:0!important;
  max-height:0!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  overflow:hidden!important;
}
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-detached="1"]>.gatto-room-gallery,
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-detached>.gatto-room-gallery{
  min-height:0!important;
  height:100%!important;
  max-height:100%!important;
  align-content:center!important;
  align-items:center!important;
  justify-content:center!important;
  overflow:hidden!important;
}
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-detached="1"] .gatto-room-media,
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-detached .gatto-room-media{
  display:grid!important;
  place-items:center!important;
  overflow:hidden!important;
}
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-detached="1"] .gatto-room-video,
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-detached .gatto-room-video{
  inset:0!important;
  width:100%!important;
  height:100%!important;
  max-width:100%!important;
  max-height:100%!important;
  margin:auto!important;
  object-fit:contain!important;
  object-position:50% 50%!important;
  transform:none!important;
  transform-origin:center center!important;
}

/* Build 10.04: somente nas superfícies de apresentação (Tela cheia e
   Destacar Sala), a barra canônica de controles fica ancorada no rodapé da
   área visível. O modo normal não participa desta regra. Os popovers já usam
   data-placement="above" nesses estados e continuam abrindo acima da barra. */
.gatto-room-fullscreen-host .chat-room-sidepanel-v972.gatto-room-shell,
.chat-room-sidepanel-v972.gatto-room-shell:fullscreen,
.chat-room-sidepanel-v972.gatto-room-shell:-webkit-full-screen,
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-fullscreen="1"],
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-fullscreen,
.gatto-room-detached-host .chat-room-sidepanel-v972.gatto-room-shell,
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-detached="1"],
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-detached{
  display:flex!important;
  flex-direction:column!important;
  align-items:stretch!important;
  height:calc(100dvh - 16px)!important;
  max-height:calc(100dvh - 16px)!important;
}
.gatto-room-fullscreen-host .chat-room-sidepanel-v972.gatto-room-shell>.gatto-room-gallery,
.chat-room-sidepanel-v972.gatto-room-shell:fullscreen>.gatto-room-gallery,
.chat-room-sidepanel-v972.gatto-room-shell:-webkit-full-screen>.gatto-room-gallery,
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-fullscreen="1"]>.gatto-room-gallery,
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-fullscreen>.gatto-room-gallery,
.gatto-room-detached-host .chat-room-sidepanel-v972.gatto-room-shell>.gatto-room-gallery,
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-detached="1"]>.gatto-room-gallery,
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-detached>.gatto-room-gallery{
  flex:1 1 auto!important;
  width:100%!important;
  height:auto!important;
  min-height:0!important;
}
.gatto-room-fullscreen-host .chat-room-sidepanel-v972.gatto-room-shell>.gatto-room-controls-wrap,
.chat-room-sidepanel-v972.gatto-room-shell:fullscreen>.gatto-room-controls-wrap,
.chat-room-sidepanel-v972.gatto-room-shell:-webkit-full-screen>.gatto-room-controls-wrap,
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-fullscreen="1"]>.gatto-room-controls-wrap,
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-fullscreen>.gatto-room-controls-wrap,
.gatto-room-detached-host .chat-room-sidepanel-v972.gatto-room-shell>.gatto-room-controls-wrap,
.chat-room-sidepanel-v972.gatto-room-shell[data-gatto-room-detached="1"]>.gatto-room-controls-wrap,
.chat-room-sidepanel-v972.gatto-room-shell.is-gatto-room-detached>.gatto-room-controls-wrap{
  flex:0 0 auto!important;
  align-self:stretch!important;
  margin-top:auto!important;
  margin-bottom:0!important;
  position:relative!important;
}

/* Build 10.07 — emojis de mensagens da Sala seguem a escala canônica do Chat. */
.gatto-room-message-text .chat-v1007-emoji-inline{display:inline-block!important;font-family:"Segoe UI Emoji","Noto Color Emoji","Apple Color Emoji",sans-serif!important;font-size:2.25em!important;font-variant-emoji:emoji;line-height:.80!important;vertical-align:-.20em!important;min-width:.88em}
.gatto-room-message-text.chat-v1007-emoji-only{font-family:"Segoe UI Emoji","Noto Color Emoji","Apple Color Emoji",sans-serif!important;font-variant-emoji:emoji;overflow:visible!important}
.gatto-room-message-text.chat-v1007-emoji-one{font-size:3.4rem!important;line-height:1.04!important}
.gatto-room-message-text.chat-v1007-emoji-few{font-size:2.7rem!important;line-height:1.08!important}
.gatto-room-message-text.chat-v1007-emoji-many{font-size:2rem!important;line-height:1.12!important}
.gatto-room-message-text.chat-v1007-emoji-only .chat-v1007-emoji-inline{font-size:inherit!important;line-height:inherit!important;vertical-align:baseline!important;min-width:0}


/* === GattoMusic 10.08: Sala mantém emojis no tamanho normal === */
.gatto-room-message-text .chat-v1007-emoji-inline{
  font-size:inherit!important;
  line-height:inherit!important;
  vertical-align:baseline!important;
  min-width:0!important;
}
.gatto-room-message-text.chat-v1007-emoji-only,
.gatto-room-message-text.chat-v1007-emoji-one,
.gatto-room-message-text.chat-v1007-emoji-few,
.gatto-room-message-text.chat-v1007-emoji-many{
  font-size:inherit!important;
  line-height:inherit!important;
}
/* === fim GattoMusic 10.08 === */

/* Build 10.35 — emoji grande e idêntico no Chat privado e no Chat da Sala. */
#chatMessageList .chat-message-text .chat-v1007-emoji-inline,
.gatto-room-message-text .chat-v1007-emoji-inline{display:inline-block!important;font-family:"Segoe UI Emoji","Noto Color Emoji","Apple Color Emoji",sans-serif!important;font-size:2.25em!important;line-height:.82!important;vertical-align:-.18em!important;min-width:.88em!important}
#chatMessageList .chat-message-text.chat-v1007-emoji-one,
.gatto-room-message-text.chat-v1007-emoji-one{font-size:clamp(4.15rem,6.7vw,5.8rem)!important;line-height:1.03!important}
#chatMessageList .chat-message-text.chat-v1007-emoji-few,
.gatto-room-message-text.chat-v1007-emoji-few{font-size:clamp(3.25rem,5.4vw,4.55rem)!important;line-height:1.07!important}
#chatMessageList .chat-message-text.chat-v1007-emoji-many,
.gatto-room-message-text.chat-v1007-emoji-many{font-size:clamp(2.45rem,4.1vw,3.5rem)!important;line-height:1.10!important}
#chatMessageList .chat-message-text.chat-v1007-emoji-only .chat-v1007-emoji-inline,
.gatto-room-message-text.chat-v1007-emoji-only .chat-v1007-emoji-inline{font-size:inherit!important;line-height:inherit!important;vertical-align:baseline!important;min-width:0!important}


/* Build 10.36 — gaps verticais uniformes e emojis em escala ~2x. */
.chat-room-sidepanel-v972.gatto-room-shell.is-open:not([data-gatto-room-detached="1"]):not(.is-gatto-room-detached):not(:fullscreen){
  grid-template-rows:auto auto auto minmax(96px,1fr) auto!important;
  gap:10px!important;
}
#chatMessageList .chat-message-text .chat-v1007-emoji-inline,
.gatto-room-message-text .chat-v1007-emoji-inline{font-size:2em!important;line-height:1!important;vertical-align:-.08em!important;min-width:.7em!important}
#chatMessageList .chat-message-text.chat-v1007-emoji-one,
.gatto-room-message-text.chat-v1007-emoji-one{font-size:clamp(2.05rem,3.35vw,2.9rem)!important;line-height:1.08!important}
#chatMessageList .chat-message-text.chat-v1007-emoji-few,
.gatto-room-message-text.chat-v1007-emoji-few{font-size:clamp(1.7rem,2.7vw,2.3rem)!important;line-height:1.10!important}
#chatMessageList .chat-message-text.chat-v1007-emoji-many,
.gatto-room-message-text.chat-v1007-emoji-many{font-size:clamp(1.35rem,2.05vw,1.8rem)!important;line-height:1.12!important}
#chatMessageList .chat-message-text.chat-v1007-emoji-only .chat-v1007-emoji-inline,
.gatto-room-message-text.chat-v1007-emoji-only .chat-v1007-emoji-inline{font-size:inherit!important;line-height:inherit!important;vertical-align:baseline!important;min-width:0!important}
