/* The attendee stage is scoped separately from registration and host pages. */
body.attendee-room-active {
  --room-toolbar-height: 82px;
  --room-actions-space: 330px;
  margin: 0;
  overflow: hidden;
}

body.attendee-room-active > .site-header,
body.attendee-room-active > footer {
  display: none;
}

.attendee-room-active #app {
  min-width: 0;
}

.attendee-room-active .viewing-room {
  --desktop-card-width: clamp(280px, 26vw, 350px);
  --cards-width: clamp(300px, 26vw, 350px);
  --video-aspect: 1.77777778;
  width: 100%;
  max-width: none;
  height: calc(100vh - var(--admin-preview-height, 0px));
  height: calc(100dvh - var(--admin-preview-height, 0px));
  margin: 0;
  padding: 0 19px var(--room-toolbar-height);
}

.attendee-room-active .viewing-room .viewing-grid {
  height: calc((100vh - var(--admin-preview-height, 0px)) - var(--room-toolbar-height));
  height: calc((100dvh - var(--admin-preview-height, 0px)) - var(--room-toolbar-height));
  min-height: 0;
  grid-template-areas: "video sidebar";
  grid-template-rows: minmax(0, 1fr);
  align-items: stretch;
  row-gap: 0;
}

.attendee-room-active .viewing-room.cards-open .viewing-grid {
  column-gap: 24px;
}

.attendee-room-active .video-column {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  min-height: 0;
  height: 100%;
  padding: 15px 0;
}

.attendee-room-active .viewing-room .video-column .player-wrap {
  background: #000;
  flex: 0 1 auto;
  width: min(100%, calc(((100vh - var(--admin-preview-height, 0px)) - var(--room-toolbar-height) - 30px) * 1.77777778));
  width: min(100%, calc(((100dvh - var(--admin-preview-height, 0px)) - var(--room-toolbar-height) - 30px) * 1.77777778));
  height: auto;
  min-height: 0;
  max-height: calc((100vh - var(--admin-preview-height, 0px)) - var(--room-toolbar-height) - 30px);
  max-height: calc((100dvh - var(--admin-preview-height, 0px)) - var(--room-toolbar-height) - 30px);
  aspect-ratio: 16 / 9;
  margin: 0;
}

.attendee-room-active .player-wrap iframe,
.attendee-room-active .player-wrap video,
.attendee-room-active .player-wrap .video-placeholder {
  width: 100%;
  height: 100%;
  min-height: 0;
}

.attendee-room-active .player-wrap video {
  object-fit: contain;
}

.attendee-room-active .player-wrap .video-placeholder {
  justify-content: safe center;
  overflow: auto;
}

.attendee-room-active .viewing-room.cards-open .watch-sidebar {
  height: 100%;
  min-height: 0;
  max-height: 100%;
  overflow: hidden;
}

.attendee-room-active .viewing-room .sidebar-controls {
  top: 10px;
  right: 2px;
}

.attendee-room-active .viewing-room .interaction-pane {
  height: 100%;
  min-height: 0;
  max-height: 100%;
  padding: 50px 3px 16px;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
}

.attendee-room-active .viewing-room .interaction-history > div {
  max-height: none;
  overflow: visible;
}

/* The completed room replaces the stage without moving the controls or cards. */
.attendee-room-active .video-column > #session-exit {
  position: absolute;
  inset: 15px 0;
  z-index: 6;
  display: flex;
  flex-direction: column;
  justify-content: safe center;
  align-items: center;
  gap: 12px;
  margin: 0;
  padding: 24px;
  overflow: auto;
  background: var(--paper, #fafafa);
  border: 0;
  text-align: center;
  overflow-wrap: anywhere;
}

.attendee-room-active .video-column > #session-exit > * {
  max-width: 640px;
  flex-shrink: 0;
}

.attendee-room-active .video-column > #session-exit p,
.attendee-room-active .video-column > #session-exit h2 {
  margin: 0;
}

/* Scroll a crowded toolbar horizontally; never drop controls behind chat. */
.attendee-room-active .room-toolbar {
  position: fixed;
  left: 18px;
  right: var(--room-actions-space);
  bottom: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 10px;
  height: var(--room-toolbar-height);
  min-width: 0;
  padding: 10px 3px;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: thin;
}

.attendee-room-active .room-toolbar > * {
  flex: 0 0 auto;
}

.attendee-room-active .room-toolbar .watch-tools {
  width: auto;
  min-height: 0;
  margin: 0;
}

.attendee-room-active .room-toolbar .bookmark-toggle,
.attendee-room-active .room-toolbar #session-info-toggle,
.attendee-room-active .room-toolbar .button,
.attendee-room-active .room-toolbar .replay-chapters > summary {
  width: auto;
  min-height: 40px;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--green);
  font-size: 13px;
  line-height: 1.4;
  white-space: nowrap;
}

.attendee-room-active .room-toolbar .room-experience-bar {
  min-width: 0;
  flex-wrap: nowrap;
  gap: 10px;
  margin: 0;
  font-size: 12px;
}

.attendee-room-active .room-toolbar .room-experience-bar [data-pause-remaining] {
  flex-basis: auto;
  max-width: 240px;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.attendee-room-active .room-toolbar .room-experience-bar [data-pause-remaining]:empty {
  display: none;
}

.attendee-room-active .room-toolbar .video-caption {
  justify-content: flex-start;
  gap: 10px;
  max-width: 300px;
  margin: 0;
  font-size: 11px;
  line-height: 1.4;
  white-space: normal;
}

.attendee-room-active .room-toolbar .video-caption > * {
  min-width: 0;
  overflow-wrap: anywhere;
}

.attendee-room-active .room-toolbar .video-caption > #player-status {
  max-height: 56px;
  overflow-y: auto;
}

/* Chapters remain real native details; the expanded list floats above the bar. */
.attendee-room-active .room-toolbar .replay-chapters {
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
}

.attendee-room-active .room-toolbar .replay-chapters > summary {
  cursor: pointer;
}

.attendee-room-active .room-toolbar .replay-chapters > .small-copy {
  position: fixed;
  left: 18px;
  bottom: calc(var(--room-toolbar-height) + min(280px, 40dvh));
  z-index: 23;
  width: min(420px, calc(100% - 36px));
  margin: 0;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-bottom: 0;
  border-radius: 14px 14px 0 0;
  background: #fff;
  color: var(--muted);
}

.attendee-room-active .room-toolbar .replay-chapters > nav {
  position: fixed;
  left: 18px;
  bottom: var(--room-toolbar-height);
  z-index: 23;
  width: min(420px, calc(100% - 36px));
  height: min(280px, 40dvh);
  max-height: min(280px, 40dvh);
  padding: 8px;
  border: 1px solid var(--line);
  border-top: 0;
  border-radius: 0 0 14px 14px;
  background: #fff;
  box-shadow: 0 12px 32px #18181826;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.attendee-room-active .viewing-room .room-actions {
  right: 18px;
  bottom: 16px;
  max-width: calc(var(--room-actions-space) - 28px);
}

.attendee-room-active .viewing-room .room-actions .button,
.attendee-room-active .viewing-room .chat-dock {
  min-height: 44px;
  padding: 10px 14px;
  font-size: 13px;
}

/* Information is available on demand without taking height from the recording. */
.attendee-room-active #session-info {
  position: fixed;
  z-index: 35;
  width: min(320px, calc(100% - 16px));
  max-width: calc(100% - 16px);
  max-height: calc((100vh - var(--admin-preview-height, 0px)) - var(--room-toolbar-height) - 24px);
  max-height: calc((100dvh - var(--admin-preview-height, 0px)) - var(--room-toolbar-height) - 24px);
  margin: 0;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--ink);
  box-shadow: 0 18px 60px #18181833;
  overflow: auto;
}

.attendee-room-active #session-info[open] {
  display: flex;
  flex-direction: column;
  animation: room-info-reveal .18s ease-out;
}

.attendee-room-active #session-info::backdrop {
  background: #18181855;
}

.attendee-room-active #session-info .session-info-head,
.attendee-room-active #session-info .bookmark-drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex: 0 0 auto;
  padding: 16px 20px;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}

.attendee-room-active #session-info .session-info-head h2 {
  margin: 0;
  font-size: 23px;
}

.attendee-room-active #session-info-close {
  position: absolute;
  right: 4px;
  top: 4px;
  width: 32px;
  height: 32px;
  background: transparent;
  border: 0;
}

.attendee-room-active #session-info .session-info-body,
.attendee-room-active #session-info .bookmark-drawer-body {
  min-width: 0;
  min-height: 0;
  padding: 20px 40px 16px 16px;
  overflow-y: auto;
  overscroll-behavior: contain;
  overflow-wrap: anywhere;
}

.attendee-room-active #session-info .session-info-status {
  flex-shrink: 0;
  margin: 16px 20px 0;
}

.attendee-room-active #session-info .session-details {
  display: block;
}

.attendee-room-active #session-info .rehearsal-notice {
  width: 100%;
  margin: 20px 0 0;
}

@keyframes room-info-reveal {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}

@media (max-width: 760px) {
  body.attendee-room-active {
    --room-toolbar-height: calc(132px + env(safe-area-inset-bottom));
    overflow-y: auto;
    overflow-x: hidden;
  }

  .attendee-room-active .viewing-room {
    height: auto;
    min-height: calc(100vh - var(--admin-preview-height, 0px));
    min-height: calc(100dvh - var(--admin-preview-height, 0px));
    padding: 0 12px var(--room-toolbar-height);
  }

  .attendee-room-active .viewing-room .viewing-grid,
  .attendee-room-active .viewing-room.cards-open .viewing-grid {
    grid-template-areas: "video" "sidebar";
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: minmax(0, 1fr) auto;
    column-gap: 0;
  }

  .attendee-room-active .viewing-room.cards-open .viewing-grid {
    height: auto;
    grid-template-rows: auto auto;
    align-content: start;
  }

  .attendee-room-active .viewing-room.cards-open .video-column {
    height: auto;
    padding: 12px 0 0;
  }

  .attendee-room-active .viewing-room.cards-open .video-column:has(> #session-exit) {
    min-height: min(440px, calc((100dvh - var(--admin-preview-height, 0px)) - var(--room-toolbar-height)));
  }

  .attendee-room-active .viewing-room.cards-open .watch-sidebar {
    height: auto;
    max-height: none;
    margin: 12px 0 0;
    overflow: visible;
  }

  .attendee-room-active .viewing-room .interaction-pane {
    width: 100%;
    height: auto;
    max-height: none;
    padding: 50px 3px 10px;
    overflow: visible;
  }

  .attendee-room-active .video-placeholder {
    padding: 12px;
  }

  .attendee-room-active .video-placeholder .play-symbol {
    display: none;
  }

  .attendee-room-active .video-placeholder h2 {
    margin-bottom: 8px;
    font-size: clamp(14px, 4.6vw, 18px);
    line-height: 1.2;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    overflow: hidden;
    flex-shrink: 0;
  }

  .attendee-room-active .video-placeholder p {
    margin-bottom: 10px;
    font-size: 11px;
    line-height: 1.4;
  }

  .attendee-room-active .video-placeholder .button {
    min-height: 44px;
    padding: 9px 12px;
    font-size: 12px;
  }

  .attendee-room-active .room-toolbar {
    left: 12px;
    right: 12px;
    bottom: calc(66px + env(safe-area-inset-bottom));
    height: 66px;
    gap: 8px;
    padding: 8px 3px;
    background: var(--paper);
  }

  .attendee-room-active .room-toolbar .bookmark-toggle,
  .attendee-room-active .room-toolbar #session-info-toggle,
  .attendee-room-active .room-toolbar .button,
  .attendee-room-active .room-toolbar .replay-chapters > summary {
    min-height: 44px;
    font-size: 12px;
  }

  .attendee-room-active .viewing-room .room-actions {
    right: 12px;
    bottom: calc(12px + env(safe-area-inset-bottom));
    max-width: calc(100% - 24px);
    gap: 8px;
  }

  .attendee-room-active .viewing-room .room-actions .button,
  .attendee-room-active .viewing-room .chat-dock {
    padding: 10px 12px;
    font-size: 12px;
  }

  .attendee-room-active .viewing-room .room-chat {
    right: 12px;
    bottom: calc(66px + env(safe-area-inset-bottom));
    width: calc(100% - 24px);
    max-height: calc((100dvh - var(--admin-preview-height, 0px)) - 84px - env(safe-area-inset-bottom));
  }

  .attendee-room-active #session-info {
    width: calc(100% - 24px);
    max-width: calc(100% - 24px);
    max-height: calc((100dvh - var(--admin-preview-height, 0px)) - 24px);
  }

  .attendee-room-active #session-info .session-info-head,
  .attendee-room-active #session-info .session-info-body {
    padding: 16px;
  }

  .attendee-room-active #session-info .room-title h1 {
    font-size: 25px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .attendee-room-active .viewing-room .viewing-grid,
  .attendee-room-active .viewing-room .watch-sidebar {
    transition: none;
    transform: none;
  }

  .attendee-room-active #session-info[open] {
    animation: none;
  }
}

.attendee-room-active #session-info .session-info-head h2{font-size:19px}
.attendee-room-active #session-info .room-title{margin:12px 0;display:block}
.attendee-room-active #session-info .room-title h3{font-size:18px;margin:0 0 8px}
.attendee-room-active #session-info .room-title p,.attendee-room-active #session-info .about-session p{font-size:14px;line-height:1.6}
.attendee-room-active #session-info .webinar-about{margin:16px 0}
.attendee-room-active #session-info .webinar-about summary{cursor:pointer;font-weight:650}
.attendee-room-active #session-info .rehearsal-notice{margin:0 0 12px;padding:0;border:0;background:none}
.attendee-room-active #session-info .attendee-return-tools{margin-top:0}

.player-identity{display:none}
.attendee-room-active .viewing-room:fullscreen{background:var(--paper)}
.room-exit-brand{font-size:16px;font-weight:700;color:var(--green)}
.room-exit-webinar-title{font-size:clamp(24px,3vw,38px);max-width:820px;overflow-wrap:anywhere}
.room-exit-message{font-size:18px;margin:0}
@media(min-width:761px){
  .attendee-room-active .player-identity{display:flex;position:absolute;inset:0 0 auto;z-index:3;flex-direction:column;gap:6px;padding:22px 24px 32px;background:linear-gradient(#0009,transparent);color:white;pointer-events:none;opacity:1;transition:opacity .25s ease;text-align:left}
  .attendee-room-active .player-identity strong{font-size:clamp(17px,1.7vw,25px);line-height:1.35;font-weight:600;overflow-wrap:anywhere;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
  .attendee-room-active .player-identity span{font-size:13px;line-height:1.4;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  .attendee-room-active .player-identity.identity-faded{opacity:0}
  .attendee-room-active .player-wrap:focus-within .player-identity{opacity:1}
  .attendee-room-active .has-player-identity>#youtube-player>h2,.attendee-room-active .has-player-identity>#youtube-player>p{display:none}
}
@media(prefers-reduced-motion:reduce){.attendee-room-active .player-identity{transition:none}}

/* A pin is a timed shortcut above the recording, not a second side-card form. */
.attendee-room-active .video-column{flex-direction:column;--pin-height:0px}
.attendee-room-active .video-column:has(#pinned-interactions:not([hidden])){--pin-height:48px}
.attendee-room-active #pinned-interactions{flex:none;width:min(100%,calc(((100dvh - var(--admin-preview-height, 0px)) - var(--room-toolbar-height) - 30px - var(--pin-height))*var(--video-aspect)))}
.attendee-room-active .pinned-banner{display:flex;align-items:center;justify-content:space-between;gap:16px;height:48px;padding:6px 10px 6px 20px;background:var(--green);color:#fff;border-radius:12px 12px 0 0;font-size:14px}
.attendee-room-active .pinned-banner>span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0}
.attendee-room-active .pinned-banner .button{flex:none;min-height:34px;padding:5px 16px;background:var(--accent);color:var(--green)}
.attendee-room-active .viewing-room .video-column .player-wrap{width:min(100%,calc(((100dvh - var(--admin-preview-height, 0px)) - var(--room-toolbar-height) - 30px - var(--pin-height))*var(--video-aspect)));max-height:calc((100dvh - var(--admin-preview-height, 0px)) - var(--room-toolbar-height) - 30px - var(--pin-height))}
.attendee-room-active #pinned-interactions:not([hidden])+.player-wrap{border-top-left-radius:0;border-top-right-radius:0}
.attendee-room-active .room-chat .chat-head{margin:0;padding-right:36px}
.attendee-room-active .room-chat .chat-head h3{font-size:19px;margin:0}
.attendee-room-active .room-chat .chat-welcome{font-size:14px;line-height:1.5;margin:10px 0 16px;color:var(--muted)}
@media(max-width:760px){
  .attendee-room-active #pinned-interactions{width:100%}
  .attendee-room-active .viewing-room .video-column .player-wrap{width:100%;max-height:none}
  .attendee-room-active .pinned-banner{padding-left:12px;gap:8px}
}

.attendee-room-active .room-chat .message.automated{border:0;background:#f5f5f5}

/* Keep auxiliary panels aligned with the card body, excluding its icon rail. */
@media(min-width:761px){
  .attendee-room-active .viewing-room .room-chat,
  .attendee-room-active .viewing-room .bookmark-drawer{
    width:var(--aux-card-width,calc(var(--desktop-card-width) - 10px));right:var(--aux-card-right,81px);left:auto;
    bottom:calc(var(--room-toolbar-height) + 8px);margin:0;
    max-height:calc((100dvh - var(--admin-preview-height, 0px)) - var(--room-toolbar-height) - 24px);box-sizing:border-box;
  }
  .attendee-room-active .viewing-room .video-column .player-wrap{aspect-ratio:var(--video-aspect)}
  .attendee-room-active .player-identity[data-size=small] strong{font-size:clamp(14px,1.3vw,19px)}
  .attendee-room-active .player-identity[data-size=large] strong{font-size:clamp(21px,2.2vw,34px)}
  .attendee-room-active .player-identity[data-position$=center]{text-align:center}
  .attendee-room-active .player-identity[data-position$=right]{text-align:right}
  .attendee-room-active .player-identity[data-position^=bottom]{inset:auto 0 0;padding:32px 24px 22px;background:linear-gradient(transparent,#0009)}
}

/* Host identity, compact bubbles and composer follow the reference chat layout. */
.host-avatar{display:inline-flex;align-items:center;justify-content:center;flex:none;width:36px;height:36px;border-radius:50%;overflow:hidden;background:var(--green,#171717);color:#fff;font-size:12px;font-weight:700;vertical-align:middle}
.host-avatar img{display:block;width:100%;height:100%;object-fit:cover}
.attendee-room-active .chat-dock .host-avatar{width:28px;height:28px;margin-right:4px;font-size:10px}
.attendee-room-active .room-chat .chat-head{display:flex;gap:10px;align-items:center;padding-right:24px}
.attendee-room-active .chat-host-heading{min-width:0;flex:1;overflow-wrap:anywhere}
.attendee-room-active .room-chat .chat-host-heading strong{font-size:15px;display:block}
.attendee-room-active .room-chat .chat-head h3{font-size:11px;font-weight:400;color:var(--muted);margin:3px 0 0}
.attendee-room-active .room-chat #refresh-chat{min-width:28px;width:28px;min-height:28px;padding:0;border:0}
.attendee-room-active .room-chat .chat-welcome{font-size:12px;margin:12px 0}
.attendee-room-active .room-chat .chat-entry{margin:0 0 14px;max-width:94%}
.attendee-room-active .room-chat .chat-entry-content>small{display:block;font-size:11px;color:var(--muted);margin:0 0 5px;overflow-wrap:anywhere}
.attendee-room-active .room-chat .chat-entry .message{margin:0;padding:10px 12px;background:#404040;color:white;border:0;border-radius:4px 16px 16px 16px;font-size:13px;line-height:1.5}
.attendee-room-active .room-chat .chat-entry-self{margin-left:auto}
.attendee-room-active .room-chat .chat-entry-self .chat-entry-content>small{text-align:right}
.attendee-room-active .room-chat .chat-entry-self .message{background:var(--green);border-radius:16px 4px 16px 16px}
.attendee-room-active .room-chat .chat-form{display:flex;flex-direction:column;gap:4px;border:1px solid var(--line);border-radius:18px;padding:8px;margin-top:12px}
.attendee-room-active .room-chat .chat-form textarea{border:0;box-shadow:none;background:transparent;min-height:62px;padding:6px;font-size:13px;resize:vertical}
.attendee-room-active .room-chat .chat-send{align-self:flex-end;width:32px;height:32px;min-height:32px;padding:0;border-radius:50%;font-size:21px;line-height:1}
.attendee-room-active .room-chat .question-note{font-size:10px;margin:10px 0 0}

@media(max-width:760px){.attendee-room-active .room-chat .chat-send{width:44px;height:44px;min-height:44px}}

.attendee-room-active .room-chat .chat-entry-content{min-width:0;flex:1}.attendee-room-active .room-chat .chat-entry>.host-avatar{width:28px;height:28px;flex:0 0 28px;margin-top:17px}.attendee-room-active .room-chat .chat-entry{display:flex;gap:8px;align-items:flex-start}

/* Required responses sit over the recording; chat remains outside the region. */
.attendee-room-active .required-interaction-overlay{position:absolute;inset:15px 0;z-index:15;display:flex;align-items:safe center;justify-content:center;overflow:auto;overscroll-behavior:contain;padding:20px;background:#000a;border-radius:12px}
.attendee-room-active .required-interaction-overlay>.interaction-card{position:relative;inset:auto;transform:none;animation:none;flex:0 1 480px;width:100%;max-width:480px;min-width:0;max-height:none;margin:0;background:var(--paper,#fff);color:var(--ink);overflow-wrap:anywhere}
.attendee-room-active .required-interaction-overlay:focus-visible{outline:3px solid #171717;outline-offset:-3px}
.attendee-room-active .watch-sidebar[inert]{pointer-events:none}
@media(max-width:760px){
  .attendee-room-active .required-interaction-overlay{position:fixed;inset:0;z-index:25;border-radius:0;padding:20px 12px calc(82px + env(safe-area-inset-bottom));background:var(--paper,#fff)}
  .attendee-room-active .required-interaction-overlay>.interaction-card{flex-basis:100%;max-width:100%}
}

/* Registration for a required next webinar stays inside the recording area.
   A non-modal dialog leaves the independent chat controls reachable. */
.attendee-room-active .next-webinar-dialog[data-required-next]{position:absolute;inset:15px 0;z-index:16;width:100%;height:calc(100% - 30px);min-height:0;max-width:none;max-height:none;margin:0;background:var(--paper,#fff);border-radius:12px}
.attendee-room-active .next-webinar-dialog[data-required-next] .card-dialog-heading{position:sticky;top:-26px;background:var(--paper,#fff);padding:12px 0;z-index:1;flex-wrap:wrap;align-items:center}
.attendee-room-active .next-webinar-dialog[data-required-next] [data-next-deadline]{flex:1 1 130px;margin:0}
@media(max-width:760px){
  .attendee-room-active .next-webinar-dialog[data-required-next]{position:fixed;inset:0;z-index:26;width:100%;height:100%;max-height:(100dvh - var(--admin-preview-height, 0px));border-radius:0;padding:18px 12px calc(82px + env(safe-area-inset-bottom))}
  .attendee-room-active .next-webinar-dialog[data-required-next] .card-dialog-heading{top:-18px}
}

.attendee-room-active .required-interaction-overlay .required-deadline{color:var(--ink);border-top:1px solid var(--line);padding-top:12px;margin:16px 0 0;overflow-wrap:anywhere}

/* Admin-only controls stay outside attendee menus and reserve their own space. */
.admin-rehearsal-toolbar{display:flex;align-items:center;gap:12px;flex-wrap:wrap;padding:10px 20px;background:#f5f5f5;border-bottom:1px solid #e5e5e5;color:var(--ink);font-size:13px}
.admin-rehearsal-toolbar p{margin:2px 0;font-size:12px}
.admin-rehearsal-toolbar label{display:flex;align-items:center;gap:8px;margin:0;font-size:13px}
.admin-rehearsal-toolbar select{width:auto;margin:0;padding:7px 28px 7px 10px;font-size:13px}
.admin-rehearsal-toolbar .preview-mode-note{flex-basis:100%;color:var(--muted)}
@media(max-width:760px){.admin-rehearsal-toolbar{padding:8px 12px;gap:8px}.admin-rehearsal-toolbar>div{flex-basis:100%}.admin-rehearsal-toolbar label{flex:1}.admin-rehearsal-toolbar select{max-width:150px}.admin-rehearsal-toolbar .preview-mode-note{font-size:11px}}

/* Open panels and their trigger controls share a safe edge, including halos.
   Keep this gap independent of the contents/height of each auxiliary panel. */
body.attendee-room-active .viewing-room .bookmark-drawer,
body.attendee-room-active .viewing-room .room-chat {
  bottom: calc(var(--room-toolbar-height) + 16px);
  max-height: calc(100dvh - var(--admin-preview-height, 0px) - var(--room-toolbar-height) - 32px);
}
body.attendee-room-active #bookmark-form > .button + .button { margin-top: 12px; }
body.attendee-room-active #bookmark-more { margin-top: 12px; }

@media (min-width: 761px) {
  body.attendee-room-active .viewing-room .room-actions { min-height: 50px; }
  body.attendee-room-active .room-toolbar #session-info-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    min-width: 48px;
    height: 48px;
    min-height: 48px;
    padding: 0;
    line-height: 1;
  }
  body.attendee-room-active .room-toolbar #session-info-toggle::before { line-height: 1; }
}
@media (max-width: 760px) {
  body.attendee-room-active .viewing-room .bookmark-drawer {
    left: 12px;
    right: 12px;
    width: calc(100% - 24px);
    max-width: none;
    border: 1px solid var(--line);
    border-radius: 20px;
  }
}

/* More options: compact optional sections, with space between content and tools. */
.attendee-room-active #session-info .session-info-head { padding:16px 52px 12px 20px; flex-shrink:0; }
.attendee-room-active #session-info .session-info-head h2 { font-size:18px; line-height:1.35; overflow-wrap:anywhere; }
.attendee-room-active #session-info-close { top:8px; right:8px; min-width:36px; min-height:36px; }
.attendee-room-active #session-info .session-info-body { display:flex; flex-direction:column; gap:18px; padding:16px 20px 20px; }
.attendee-room-active #session-info .session-info-custom { display:flex; flex-direction:column; gap:12px; }
.attendee-room-active #session-info .session-info-custom h3,
.attendee-room-active #session-info .session-info-custom p { margin:0; }
.attendee-room-active #session-info .session-info-custom p { white-space:pre-wrap; font-size:15px; line-height:1.6; }
.attendee-room-active #session-info .session-info-custom img { width:100%; height:auto; max-height:220px; object-fit:contain; border-radius:10px; }
.attendee-room-active #session-info .session-info-custom .button { align-self:flex-start; }
.attendee-room-active #session-info .webinar-about { margin:0; }
.attendee-room-active #session-info .session-details:empty,
.attendee-room-active #session-info .inline-actions:empty { display:none; }
.attendee-room-active .room-toolbar #session-info-toggle[hidden] { display:none!important; }
.attendee-room-active #session-info .session-details[hidden] { display:none!important; }
