/* Rooms: full-window viewing environments for the live wall (rooms.js).
   A room keeps the engine's tiles in the document and only repositions them, so no player is reloaded. Its scene is
   drawn behind and around the screens. Nothing here may sit in front of a player: frames, glows and captions stay
   outside the picture, and a caption hangs below its screen instead of covering it.
   Names: html[data-room] is the room in use; the rm- prefix and the --rm- tokens belong to this file and the room
   modules (the section design already uses "room" for its workspace button). */

/* ---------- The page while a room is open ---------- */
html[data-room]:has(.broadcast-page),html[data-room] body.broadcast-page{height:100%!important;overflow:hidden!important}
html[data-room] body.broadcast-page{
  --rm-bg:#02060f;--rm-ink:#eaf9ff;--rm-dim:#8fb2c8;--rm-line:#63dcff47;--rm-accent:#63e6ff;--rm-glow:#2aa9ff;
  --rm-glass:#061428b8;--rm-warn:#ffb866;--rm-radius:3px;--rm-cap:30px;--rm-ease:cubic-bezier(.22,.8,.24,1);
  --desk-accent:var(--rm-accent);--desk-muted:var(--rm-dim);--desk-surface:var(--rm-glass);--desk-border:var(--rm-line);--desk-ink:var(--rm-ink);
  background:var(--rm-bg)!important;color:var(--rm-ink);
}
html[data-room] body.broadcast-page :is(.universe-header,.broadcast-intro,.channel-sidebar,.universe-footer,.view-switch,.toolbar,.media-notice,.wall-caption,.market-tape,.section-menu-trigger,.cinema-exit){display:none!important}
html[data-room] body.broadcast-page :is(.broadcast-grid,.workspace,.main){display:block!important;margin:0!important;padding:0!important;border:0!important;min-height:0!important;background:none!important}

/* ---------- Stage: the scene and its instruments ---------- */
.rm-stage{position:fixed;inset:0;z-index:60;overflow:hidden;direction:ltr;background:var(--rm-bg,#02060f);color:var(--rm-ink,#eaf9ff);font:12px/1.4 system-ui,-apple-system,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;contain:strict}
.rm-stage[hidden]{display:none}
.rm-scene,.rm-hud{position:absolute;inset:0}
.rm-scene{opacity:0;transition:opacity 1.1s ease}
html[data-room-ready] .rm-scene{opacity:1}
.rm-hud{pointer-events:none;opacity:0;transition:opacity .8s ease .25s}
html[data-room-ready] .rm-hud{opacity:1}
.rm-hud :is(button,a){pointer-events:auto}
.rm-sr{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}

/* ---------- The wall inside a room ---------- */
html[data-room] body.broadcast-page .main>#wall{
  position:fixed!important;inset:0!important;z-index:61;display:block!important;width:auto!important;height:auto!important;
  max-width:none!important;max-height:none!important;margin:0!important;padding:0!important;gap:0!important;
  pointer-events:none;overflow:visible!important;direction:ltr;
}
html[data-room] body.broadcast-page #wall>.tile{
  position:absolute!important;left:var(--rx,0px)!important;top:var(--ry,0px)!important;width:var(--rw,356px)!important;height:var(--rh,200px)!important;
  aspect-ratio:auto!important;min-width:0!important;min-height:0!important;margin:0!important;
  overflow:visible!important;border:0!important;border-radius:0!important;background:none!important;box-shadow:none!important;
  pointer-events:auto;z-index:1;container-type:normal;opacity:0;
  transition:left .75s var(--rm-ease),top .75s var(--rm-ease),width .75s var(--rm-ease),height .75s var(--rm-ease),opacity .5s ease;
}
html[data-room][data-room-ready] body.broadcast-page #wall>.tile{opacity:1}
html[data-room] body.broadcast-page #wall>.tile[data-rm-tier=out]{opacity:0!important;visibility:hidden;pointer-events:none}
html[data-room] body.rm-still #wall>.tile{transition:opacity .5s ease}
html[data-room] body.rm-arrive #wall>.tile{animation:rm-arrive .9s var(--rm-ease) both;animation-delay:calc(var(--ri,0)*55ms + .15s)}
@keyframes rm-arrive{from{opacity:0;transform:translateY(14px) scale(.985)}to{opacity:1;transform:none}}
/* The frame: a line and a glow around the screen, painted behind the picture. */
html[data-room] body.broadcast-page #wall>.tile::before{
  content:"";position:absolute;inset:-1px;z-index:-1;border-radius:calc(var(--rm-radius) + 1px);pointer-events:none;
  box-shadow:0 0 0 1px var(--rm-line),0 0 34px -8px var(--rm-glow);transition:box-shadow .35s ease;
}
html[data-room] body.broadcast-page #wall>.tile.listening::before{box-shadow:0 0 0 1px var(--rm-accent),0 0 44px -6px var(--rm-accent)}
html[data-room] body.broadcast-page #wall>.tile>.tile-media{
  position:absolute!important;inset:0!important;display:block!important;width:100%!important;height:100%!important;min-height:0!important;
  aspect-ratio:auto!important;overflow:visible!important;border-radius:var(--rm-radius);background:#000;
}
html[data-room] body.broadcast-page #wall .tile-media>:is(.player-host,.thumbnail,.preview-play){border-radius:var(--rm-radius);overflow:hidden}
/* The engine's small parts take the room's own colours: the play mark of a screen that waits, the ground of a screen
   without a broadcast and the ring around the reconnect key's number. */
html[data-room] body.broadcast-page #wall .preview-play{color:var(--rm-ink);background:var(--rm-glass);border:1px solid var(--rm-line)}
html[data-room] body.broadcast-page #wall .tile-media:is([data-status=offline],[data-status=unknown])::after{background:var(--rm-bg);color:var(--rm-dim)}
html[data-room] body.broadcast-page .topbar #goLiveBtn .reconnect-badge{box-shadow:0 0 0 2px var(--rm-bg)!important}
html[data-room] body.broadcast-page #wall .tile-media:fullscreen{border-radius:0}
html[data-room] body.broadcast-page #wall .tile-media:fullscreen .tile-hud{display:none!important}
/* The caption hangs below the screen: name, state and the screen's own controls. */
html[data-room] body.broadcast-page #wall .tile-hud{
  position:absolute!important;inset:100% 0 auto 0!important;height:var(--rm-cap);min-height:0!important;padding:0 1px!important;
  display:flex!important;flex-direction:row!important;align-items:center!important;justify-content:space-between;gap:10px;
  background:none!important;opacity:1!important;pointer-events:auto!important;z-index:1;
}
html[data-room] body.broadcast-page #wall .tile-ident{
  display:flex!important;flex-direction:row!important;align-items:baseline;gap:8px;min-width:0;flex:1 1 auto;color:var(--rm-ink);text-shadow:none;cursor:pointer;
}
html[data-room] body.broadcast-page #wall>.tile[data-rm-tier=hero] .tile-ident{cursor:default}
html[data-room] body.broadcast-page #wall .tile-name{
  order:2;min-width:0;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;
  font:500 12px/1.2 system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif!important;letter-spacing:.01em;color:var(--rm-ink)!important;
}
html[data-room] body.broadcast-page #wall .tile-country{
  order:3;flex:0 1 auto;min-width:0;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;
  font:10px/1.2 ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;letter-spacing:.08em;text-transform:uppercase;color:var(--rm-dim);
}
html[data-room] body.broadcast-page #wall .stream-state{
  order:1;flex:none;align-self:center;gap:5px;font:600 8.5px/1 ui-monospace,SFMono-Regular,Menlo,Consolas,monospace!important;letter-spacing:.12em;color:var(--rm-dim);
}
html[data-room] body.broadcast-page #wall .stream-state::before{width:5px;height:5px;background:var(--rm-dim)}
/* A joined script has no fixed-width face worth reading: on a right-to-left page the state takes the room's own face. */
:root[dir=rtl][data-room] body.broadcast-page #wall .stream-state{font-family:var(--rm-font,system-ui),sans-serif!important}
html[data-room] body.broadcast-page #wall .stream-state[data-state=playing]{color:var(--rm-accent)}
html[data-room] body.broadcast-page #wall .stream-state[data-state=playing]::before{background:var(--rm-accent);box-shadow:0 0 8px var(--rm-accent)}
html[data-room] body.broadcast-page #wall .stream-state:is([data-state=error],[data-state=blocked],[data-state=unknown]){color:var(--rm-warn)}
html[data-room] body.broadcast-page #wall .stream-state:is([data-state=error],[data-state=blocked],[data-state=unknown])::before{background:var(--rm-warn)}
html[data-room] body.broadcast-page #wall .tile-actions{display:flex;flex:none;gap:2px;pointer-events:auto;opacity:.5;transition:opacity .2s}
html[data-room] body.broadcast-page #wall>.tile:is(:hover,:focus-within,.listening) .tile-actions{opacity:1}
html[data-room] body.broadcast-page #wall .tile-btn{
  width:24px!important;height:24px!important;min-width:24px;min-height:24px;padding:0;border:0!important;border-radius:6px;
  background:none!important;color:var(--rm-dim)!important;cursor:pointer;
}
html[data-room] body.broadcast-page #wall .tile-btn:is(:hover,:focus-visible){color:var(--rm-ink)!important;background:#ffffff14!important}
html[data-room] body.broadcast-page #wall .tile-btn svg{width:14px;height:14px}
html[data-room] body.broadcast-page #wall>.tile.listening .listen-btn{background:none!important;color:var(--rm-accent)!important;border:0!important}
html[data-room] body.broadcast-page #wall>.tile[data-rm-tier=hero] .rm-focus-btn{display:none}
html:not([data-room]) :is(.rm-focus-btn,.rm-zap-btn){display:none!important}
html[data-room] body.broadcast-page #wall>.tile:not([data-rm-tier=hero]) .rm-zap-btn,html[data-room] body.broadcast-page #wall[data-count="1"] .rm-zap-btn{display:none}
/* The main screen carries a larger caption. */
html[data-room] body.broadcast-page #wall>.tile[data-rm-tier=hero] .tile-name{font-size:17px!important;font-weight:400!important;letter-spacing:0}
html[data-room] body.broadcast-page #wall>.tile[data-rm-tier=hero] .tile-country{font-size:11px}
html[data-room] body.broadcast-page #wall>.tile[data-rm-tier=hero] .stream-state{font-size:10px!important}
html[data-room] body.broadcast-page #wall>.tile[data-rm-tier=hero] .tile-btn{width:30px!important;height:30px!important}
html[data-room] body.broadcast-page #wall>.tile[data-rm-tier=hero] .tile-btn svg{width:16px;height:16px}
html[data-room] body.broadcast-page #wall .empty-state{position:absolute;inset:25% 10% auto;pointer-events:auto;color:var(--rm-ink);text-align:center}

/* ---------- Control bar: the engine's own bar, floating over the room ---------- */
html[data-room] body.broadcast-page .topbar{
  position:fixed!important;z-index:62;top:12px;left:50%;transform:translateX(-50%);
  display:flex!important;flex-wrap:nowrap;align-items:center;justify-content:center;gap:10px;
  width:max-content;max-width:calc(100vw - 20px);min-height:0!important;height:46px;margin:0!important;padding:0 8px!important;
  border:1px solid var(--rm-line);border-radius:14px;background:var(--rm-glass);
  -webkit-backdrop-filter:blur(16px) saturate(1.25);backdrop-filter:blur(16px) saturate(1.25);
  box-shadow:0 10px 40px -18px #000c;transition:opacity .6s ease;
}
html[data-room] body.rm-idle .topbar:not(:hover):not(:focus-within){opacity:.45}
html[data-room] body.broadcast-page .topbar :is(.topbar-lead,.topbar-actions){display:flex!important;flex-wrap:nowrap;align-items:center;gap:8px;min-width:0;width:auto;flex:0 1 auto}
html[data-room] body.broadcast-page .topbar :is(.brand,#shortcutsBtn,.audio-identity,.wall-health,.dock-divider,.utc-clock){display:none!important}
html[data-room] body.broadcast-page .topbar .audio-dock{display:flex!important;align-items:center;gap:8px;padding:0!important;min-width:0}
html[data-room] body.broadcast-page .topbar .audio-controls{display:flex;align-items:center;gap:8px}
html[data-room] body.broadcast-page .topbar .collection-btn{height:32px!important;min-height:32px;border-radius:9px!important;padding:0 11px;font:500 12px system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif}
/* The Economy section paints this button light on the classic wall; inside a room the room decides. */
html[data-room] body.broadcast-page .topbar .collection-btn{background:var(--rm-glass)!important;color:var(--rm-ink)!important;border-color:var(--rm-line)!important}
html[data-room] body.broadcast-page .topbar .site-tabs{border-radius:9px;padding:2px;gap:2px}
html[data-room] body.broadcast-page .topbar .site-tab{border-radius:7px!important;padding:6px 10px!important;font-size:11.5px!important}
html[data-room] body.broadcast-page .topbar .site-tab[aria-pressed=true]{background:var(--rm-accent)!important;color:#02121d!important}
html[data-room] body.broadcast-page .topbar .icon-btn{width:32px!important;height:32px!important;min-width:32px;border-radius:9px!important}
html[data-room] body.broadcast-page .topbar .volume-control output{display:none}
.rm-bar-btn{display:none;align-items:center;gap:7px;height:32px;padding:0 11px;border:1px solid var(--rm-line);border-radius:9px;background:var(--rm-glass);color:var(--rm-ink);font:500 12px system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif;cursor:pointer;white-space:nowrap}
html[data-room] .rm-bar-btn{display:inline-flex}
.rm-bar-btn:is(:hover,:focus-visible){border-color:var(--rm-accent)}
.rm-bar-btn svg{width:15px;height:15px;flex:none}
.rm-bar-btn[aria-expanded=true]{border-color:var(--rm-accent);color:var(--rm-accent)}
.rm-bar-sep{display:none;width:1px;height:20px;background:var(--rm-line);flex:none}
html[data-room] .rm-bar-sep{display:block}
@media(max-width:1020px){html[data-room] body.broadcast-page .topbar .volume-control{display:none}}
@media(max-width:820px){html[data-room] body.broadcast-page .topbar :is(#browseBtn,.site-tabs){display:none!important}.rm-bar-btn span{display:none}}

/* ---------- Room menu ---------- */
/* A room is laid out by coordinates, so its parts keep one direction in every language; text runs its own way. */
.rm-menu{
  direction:ltr;position:fixed;z-index:70;width:min(348px,calc(100vw - 24px));max-height:calc(100vh - 24px);overflow:auto;padding:8px;box-sizing:border-box;
  border:1px solid var(--rm-line,#63dcff47);border-radius:14px;background:color-mix(in srgb,var(--rm-bg,#06132a) 95%,transparent);color:var(--rm-ink,#eaf9ff);
  -webkit-backdrop-filter:blur(18px);backdrop-filter:blur(18px);box-shadow:0 24px 80px -20px #000;
  font:12px/1.4 system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif;
}
.rm-menu[hidden]{display:none}
.rm-menu h2{margin:6px 8px 8px;font:600 9.5px/1 ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;letter-spacing:.16em;text-transform:uppercase;color:var(--rm-dim,#8fb2c8)}
.rm-menu-item{display:grid;grid-template-columns:64px minmax(0,1fr) 16px;align-items:center;gap:12px;width:100%;padding:6px 8px;border:1px solid transparent;border-radius:10px;background:none;color:inherit;font:inherit;text-align:left;cursor:pointer}
.rm-menu-item:is(:hover,:focus-visible){background:#ffffff0d;border-color:var(--rm-line,#63dcff33);outline:0}
.rm-menu-item[aria-checked=true]{border-color:var(--rm-accent,#63e6ff);background:color-mix(in srgb,var(--rm-accent,#63e6ff) 9%,transparent)}
.rm-menu-item strong{display:block;font-weight:500;font-size:13px}
.rm-menu-item small{display:block;margin-top:1px;font-size:11px;color:var(--rm-dim,#8fb2c8)}
.rm-menu-item .rm-check{width:14px;height:14px;opacity:0;color:var(--rm-accent,#63e6ff)}
.rm-menu-item[aria-checked=true] .rm-check{opacity:1}
/* A swatch is a small painted picture of its room; it does not change with the room in use. */
.rm-swatch{position:relative;width:64px;height:40px;border-radius:7px;overflow:hidden;border:1px solid #ffffff1f;background:#0b1512}
.rm-swatch i{position:absolute;border-radius:1.5px;background:#dfe9e2}
.rm-swatch[data-room=classic]{background:#101915}
.rm-swatch[data-room=classic] i{background:#33473a}
.rm-swatch[data-room=nebula]{background:radial-gradient(120% 90% at 20% 10%,#2a6bffb3,transparent 60%),radial-gradient(90% 80% at 85% 30%,#22c8ff80,transparent 60%),#04103a}
.rm-swatch[data-room=nebula] i{background:#d9fbff;box-shadow:0 0 6px #37c8ff}
.rm-swatch[data-room=hearth]{background:radial-gradient(70% 46% at 50% 100%,#ff8a2e,#ff5a1a66 45%,transparent 72%),linear-gradient(#1c110b 0 66%,#2a160b 66%)}
.rm-swatch[data-room=hearth] i{background:#ffe9cf;box-shadow:0 0 6px #ff9a4a}
.rm-swatch[data-room=array]{background:radial-gradient(#c8ff3d1f 1px,transparent 1.4px) 0 0/5px 5px,#0a0c0b}
.rm-swatch[data-room=array] i{background:#c8ff3d;box-shadow:0 0 5px #c8ff3d99}
.rm-swatch[data-room=orbit]{background:radial-gradient(22% 30% at 84% 60%,#ffd28a,#ff8a3c88 45%,transparent 75%),radial-gradient(130% 90% at 50% 150%,#123a7a 0 55%,#6fd8ff 56% 57.5%,transparent 59%),#02030a}
.rm-swatch[data-room=orbit] i{background:#f5f8ff;box-shadow:0 0 5px #ffc46b}
.rm-swatch[data-room=skyline]{background:linear-gradient(90deg,#12052a 0 9%,transparent 9% 14%,#12052a 14% 26%,transparent 26% 72%,#12052a 72% 83%,transparent 83% 89%,#12052a 89%) 0 100%/100% 62% no-repeat,linear-gradient(#1b0a3d,#7a2bd0 70%,#ff3df0)}
.rm-swatch[data-room=skyline] i{background:#f6e9ff;box-shadow:0 0 6px #3df2ff}
.rm-menu-foot{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:6px;padding:7px 8px 5px;border-top:1px solid var(--rm-line,#63dcff24)}
.rm-menu-foot+.rm-menu-foot{margin-top:0}
.rm-menu-foot[hidden]{display:none}
.rm-menu-foot>span{font-size:11.5px;color:var(--rm-dim,#8fb2c8)}
.rm-menu-foot button{display:inline-flex;align-items:baseline;gap:4px;min-height:27px;padding:5px 10px;border:1px solid var(--rm-line,#63dcff47);border-radius:8px;background:none;color:var(--rm-ink,#eaf9ff);font:500 11.5px system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif;cursor:pointer}
.rm-menu-foot button:is(:hover,:focus-visible){border-color:var(--rm-accent,#63e6ff);outline:0}
.rm-menu-foot button[aria-pressed=true]{border-color:var(--rm-accent,#63e6ff);color:var(--rm-accent,#63e6ff)}
.rm-menu-foot button b{font-weight:600;font-variant-numeric:tabular-nums}
.rm-menu-foot button [hidden]{display:none}
.rm-menu-link{display:block;width:100%;box-sizing:border-box;margin-top:6px;padding:7px 9px;border:1px solid var(--rm-line,#63dcff47);border-radius:8px;background:#0006;color:var(--rm-ink,#eaf9ff);font:11px ui-monospace,SFMono-Regular,Menlo,Consolas,monospace}
.rm-menu-link[hidden]{display:none}

/* ---------- Couch mode: where the game controller's cursor stands ---------- */
html[data-room] body.broadcast-page #wall>.tile.rm-cursor::before{box-shadow:0 0 0 3px #fff,0 0 0 6px var(--rm-accent),0 0 60px -4px var(--rm-accent)}
.rm-cursor:not(.tile){outline:3px solid #fff!important;outline-offset:3px;box-shadow:0 0 0 7px var(--rm-accent,#63e6ff),0 0 30px var(--rm-accent,#63e6ff)}

/* ---------- Asleep: the sleep timer has run out ---------- */
html[data-room] body.rm-asleep .rm-scene{opacity:.28}
html[data-room] body.rm-asleep .rm-hud{opacity:.4}

/* ---------- Pager for a room's rail of further screens ---------- */
.rm-pager{position:absolute;display:flex;align-items:center;gap:6px;transform:translateX(-100%);font:600 10px/1 ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;letter-spacing:.1em;color:var(--rm-dim)}
.rm-pager[hidden]{display:none}
.rm-pager button{display:grid;place-items:center;width:24px;height:24px;padding:0;border:1px solid var(--rm-line);border-radius:7px;background:var(--rm-glass);color:var(--rm-ink);cursor:pointer}
.rm-pager button:is(:hover,:focus-visible){border-color:var(--rm-accent);color:var(--rm-accent)}
.rm-pager button:disabled{opacity:.35;cursor:default;border-color:var(--rm-line);color:var(--rm-dim)}
.rm-pager svg{width:12px;height:12px}
.rm-pager b{min-width:38px;text-align:center;font-weight:600;font-variant-numeric:tabular-nums}

/* The site's language switch stands at the right end of the bar's strip in every language (rooms.js seats it at the
   top or the bottom with the bar). Its passing hint opens beside it, where a room may have a screen, so a room leaves
   the hint out; the switch itself is always there. On a narrow window the bar moves aside for the switch. */
html[data-room] .l10n-switch{direction:ltr;--l10n-gap:12px}
html[data-room] .l10n-switch .l10n-hint{display:none!important}
@media(max-width:700px){
  html[data-room] body.broadcast-page .topbar{left:10px;transform:none;max-width:calc(100vw - 104px)}
}
/* A long collection name gives way before the bar's buttons leave the bar. */
html[data-room] body.broadcast-page .topbar .collection-btn{min-width:0!important;max-width:38vw;flex:0 1 auto}
html[data-room] body.broadcast-page .topbar #collectionName{min-width:0;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}
/* The engine's short notices appear over the control bar, where no screen can be. */
html[data-room] body.broadcast-page .toast{top:15px!important;bottom:auto!important}

/* ---------- Dock: a strip of small stills, one of every channel the room is not showing ---------- */
.rm-dock{position:absolute;display:flex;flex-direction:column;align-items:center;gap:12px}
.rm-dock[hidden]{display:none}
.rm-dock-head{display:flex;align-items:center;gap:14px;width:100%;font:600 10.5px/1 var(--rm-font,system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif);letter-spacing:.34em;text-transform:uppercase;color:var(--rm-accent);white-space:nowrap}
.rm-dock-head::before,.rm-dock-head::after{content:"";flex:1;height:1px;background:linear-gradient(90deg,transparent,var(--rm-line))}
.rm-dock-head::after{background:linear-gradient(90deg,var(--rm-line),transparent)}
.rm-dock-row{display:flex;align-items:flex-start;justify-content:center;gap:var(--rm-key-gap,11px);max-width:100%}
/* The strip slides sideways under a finger or a trackpad and rests where no still is cut (rooms.js sets how many
   stills wide it is). Its box reaches past the stills and gives that back with its margins, and it fades out
   towards its edges, so that frames, glows and the name line under a still end softly and a still slides out of
   sight instead of being cut. One row reaches 40 px to each side (under its step buttons, which stand above it),
   40 px up and 30 px down; stacked rows reach 10 px to each side, the gap under the heading up and less than the
   10 px a room keeps free under them down. The strip takes the pointer inside that box, so a swipe may start
   between two stills; no control of a room may lie under it (the room audit checks that). */
.rm-dock-strip{
  --rm-strip-reach:40px;--rm-strip-top:40px;--rm-strip-foot:30px;--rm-strip-fade:18px;--rm-strip-rise:10px;
  flex:none;box-sizing:border-box;width:calc(var(--rm-strip-w,128px) + 2*var(--rm-strip-reach));
  margin:calc(-1*var(--rm-strip-top)) calc(-1*var(--rm-strip-reach)) calc(-1*var(--rm-strip-foot));padding:var(--rm-strip-top) 0 var(--rm-strip-foot);
  overflow-x:auto;overflow-y:hidden;overscroll-behavior:contain;touch-action:pan-x;pointer-events:auto;
  scroll-snap-type:x mandatory;scroll-padding:0 var(--rm-strip-reach);scrollbar-width:none;
  -webkit-mask-image:linear-gradient(90deg,#0000,#000 var(--rm-strip-fade),#000 calc(100% - var(--rm-strip-fade)),#0000),linear-gradient(#0000,#000 var(--rm-strip-rise),#000 calc(100% - var(--rm-strip-rise)),#0000);
  mask-image:linear-gradient(90deg,#0000,#000 var(--rm-strip-fade),#000 calc(100% - var(--rm-strip-fade)),#0000),linear-gradient(#0000,#000 var(--rm-strip-rise),#000 calc(100% - var(--rm-strip-rise)),#0000);
  -webkit-mask-composite:source-in;mask-composite:intersect;
}
.rm-dock[data-stacked] .rm-dock-strip{--rm-strip-reach:10px;--rm-strip-top:12px;--rm-strip-foot:9px;--rm-strip-fade:3px;--rm-strip-rise:4px}
.rm-dock-strip::-webkit-scrollbar{display:none}
/* The track carries the stills, column by column. */
.rm-dock-track{
  display:grid;grid-auto-flow:column;grid-template-rows:repeat(var(--rm-dock-lanes,1),var(--rm-key-h,72px));grid-auto-columns:var(--rm-key-w,128px);
  gap:var(--rm-key-gap,11px);box-sizing:content-box;width:max-content;padding:0 var(--rm-strip-reach);
}
.rm-dock-row>.rm-step{position:relative;z-index:1}
/* At rest one row shows only the stills in view; the others show while the strip slides. */
.rm-dock:not([data-stacked]) .rm-dock-strip:not([data-sliding]) .rm-key[data-out]{opacity:0;pointer-events:none}
/* A key that starts playback may not be smaller than 120 by 70 (the provider's rule for such pictures). */
.rm-key{position:relative;flex:none;width:var(--rm-key-w,128px);height:var(--rm-key-h,72px);padding:0;border:0;border-radius:7px;background:var(--rm-bg);color:var(--rm-ink);cursor:pointer;scroll-snap-align:start;box-shadow:0 0 0 1.5px var(--rm-accent),0 0 20px -3px var(--rm-glow);transition:transform .22s cubic-bezier(.2,.8,.2,1),box-shadow .22s,opacity .2s}
.rm-key i{position:absolute;inset:0;display:grid;place-items:center;border-radius:7px;background:radial-gradient(circle at 34% 28%,color-mix(in srgb,var(--rm-glow) 55%,transparent),transparent 72%),var(--rm-glass);font:600 17px/1 var(--rm-font,system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif);font-style:normal;letter-spacing:.1em;color:var(--rm-ink)}
.rm-key img{position:absolute;inset:0;display:block;width:100%;height:100%;object-fit:cover;border-radius:7px}
/* The name line under a still of one row reaches at most 21 px past it on each side: inside the track's own edge,
   so that it never adds to the strip's slide, and inside the part of the strip that does not fade. */
.rm-key span{position:absolute;left:50%;top:calc(100% + 8px);transform:translateX(-50%);max-width:170px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;font:600 10px/1.2 var(--rm-font,system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif);letter-spacing:.14em;text-transform:uppercase;color:var(--rm-ink);opacity:0;transition:opacity .2s;pointer-events:none}
.rm-key:is(:hover,:focus-visible){outline:0;z-index:1;transform:translateY(-4px) scale(1.07);box-shadow:0 0 0 2px #fff,0 0 30px var(--rm-accent)}
.rm-key:is(:hover,:focus-visible,.rm-cursor) span{opacity:1}
/* Stacked rows fill the dock's box to its foot, so there is no place for a name line under them. */
.rm-dock[data-stacked] .rm-key span{display:none}
.rm-key[data-source=offline]{box-shadow:0 0 0 1.5px var(--rm-line)}
.rm-key[data-source=offline] img{filter:grayscale(.85) brightness(.5)}
.rm-step{display:grid;place-items:center;flex:none;width:27px;height:var(--rm-key-h,72px);padding:0;border:1px solid var(--rm-line);border-radius:8px;background:var(--rm-glass);color:var(--rm-ink);cursor:pointer}
.rm-step:is(:hover,:focus-visible){border-color:var(--rm-accent)}
.rm-step:disabled{opacity:.3;cursor:default}
.rm-step svg{width:14px;height:14px}
.rm-step[hidden]{display:none}
.rm-dock-steps{display:flex;gap:6px}
.rm-dock-steps:empty{display:none}
.rm-dock-steps .rm-step{width:28px;height:22px;border-radius:6px}

/* ---------- The way in from the classic wall ---------- */
body.broadcast-page .view-switch .rm-enter{display:inline-flex;align-items:center;gap:8px;margin-left:auto}
body.broadcast-page .view-switch .rm-enter svg{width:15px;height:15px}
body.broadcast-page .view-switch .rm-enter+.room-button{margin-left:0}

/* ---------- Motion ---------- */
html[data-room-motion=off] .rm-stage *,html[data-room-motion=off] #wall>.tile{animation:none!important}
@media(prefers-reduced-motion:reduce){
  html[data-room] body.broadcast-page #wall>.tile{transition:opacity .3s ease}
  html[data-room] body.rm-arrive #wall>.tile{animation:none}
  .rm-scene,.rm-hud{transition:none}
}
