/* Shared player for the Room Screen flow embeds (public/case/room-screen-*.html).
   Layout: one 1366 × 1024 room-panel artboard, scaled to fit the iframe, with progress dots under it.
   The stage follows the tbob.design theme like the Desk Screen embeds. */
:root {
  --stage: transparent;
  --dot: rgba(20, 25, 34, 0.18);
  --dot-on: #141922;
  --focus: #3b82f6;

  --busy: #ff3f4f;
  --green: #02ff62;
  --amber: #ffc718;
  --blue: #057eff;
  --ink: #141922;
  --ink-70: rgba(20, 25, 34, 0.7);
  --white-70: rgba(255, 255, 255, 0.7);
  --grey-text: #999;
  --glass-bg: rgba(118, 122, 138, 0.4);
  --glass-border: rgba(162, 167, 189, 0.42);
  --card-bg: rgba(118, 122, 138, 0.22);

  --dur: 0ms;
  --ease: linear;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { --stage: transparent; --dot: rgba(255, 255, 255, 0.2); --dot-on: #fff; color-scheme: dark; }
}
:root[data-theme="dark"] { --stage: transparent; --dot: rgba(255, 255, 255, 0.2); --dot-on: #fff; color-scheme: dark; }

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  background: var(--stage);
  font-family: "Manrope", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}
p, h1, h2 { margin: 0; }
svg.i { display: block; flex: none; }

/* The screen sits above a 56 px band that holds the progress dots (centred) and the demo
   button (bottom right, public/case/demo.js), so the button never covers the screen. */
.rs-stage {
  visibility: hidden; /* until fit() has scaled the screen (flow.js), so it never paints at the wrong size */
  position: fixed;
  inset: 12px 0 56px;
  display: flex;
  align-items: center;
  justify-content: center;
}

:root.is-fit .rs-stage { visibility: visible; }

/* ---------- Screen ---------- */
.rs-screen {
  position: relative;
  flex: none;
  width: 1366px;
  height: 1024px;
  transform-origin: center;
  transform: scale(var(--fit, 0.4));
  margin: calc((var(--fit, 0.4) - 1) * 512px) calc((var(--fit, 0.4) - 1) * 683px);
  border-radius: 20px;
  overflow: hidden;
  background: #000;
  color: #fff;
  user-select: none;
  -webkit-user-select: none;
}
.scr {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--dur) var(--ease), visibility 0s linear var(--dur);
}
.scr.is-on {
  opacity: 1;
  visibility: visible;
  transition: opacity var(--dur) var(--ease), visibility 0s;
}
/* Set for one style pass while a screen comes in (flow.js), so its parts start at rest */
.scr.is-arriving * { transition: none !important; }

/* ---------- Shared parts ---------- */
.glass {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 70px;
  padding: 0 36px;
  border: 2px solid var(--glass-border);
  border-radius: 16px;
  background: var(--glass-bg);
  -webkit-backdrop-filter: blur(17px);
  backdrop-filter: blur(17px);
  color: #fff;
  font-size: 31px;
  font-weight: 700;
  line-height: 28px;
  white-space: nowrap;
  transition: background-color 120ms, color 120ms, border-color 120ms;
}
.glass.round { width: 70px; padding: 0; border-radius: 106px; }
.glass.ghost { visibility: hidden; }
/* Pressed variant (Figma button "pressed", 9472:19768) */
.is-pressed.glass,
.is-pressed.outline {
  background: #fff;
  border-color: #fff;
  color: var(--ink);
}
.outline {
  display: inline-flex;
  align-items: center;
  height: 70px;
  padding: 0 36px;
  border: 1px solid #000;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.11);
  -webkit-backdrop-filter: blur(17px);
  backdrop-filter: blur(17px);
  color: #000;
  font-size: 31px;
  font-weight: 700;
  line-height: 28px;
  white-space: nowrap;
  transition: background-color 120ms, color 120ms, border-color 120ms;
}

/* Room header: clock + room name (Figma "header") */
.room-head {
  position: absolute;
  top: 0;
  left: 0;
  width: 1364px;
  display: flex;
  align-items: center;
  gap: 179px;
  padding: 20px 24px;
  z-index: 2;
}
.clock {
  width: 187px;
  height: 46px;
  display: flex;
  align-items: center;
  font-size: 64px;
  font-weight: 700;
  letter-spacing: -1px;
  font-feature-settings: "lnum" 1, "pnum" 1;
  white-space: nowrap;
}
.rs-screen.is-blink .clock-colon { color: transparent; }
.room-name { width: 334px; font-size: 64px; font-weight: 700; line-height: normal; }

/* Page header: back button, centred title (Figma "Find another space" header) */
.page-head {
  position: absolute;
  top: 0;
  left: 0;
  width: 1366px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  z-index: 2;
}
.page-head.is-solid {
  background: rgba(0, 0, 0, 0.6);
  -webkit-backdrop-filter: blur(32px);
  backdrop-filter: blur(32px);
}
.page-title { font-size: 64px; font-weight: 700; line-height: normal; white-space: nowrap; }

.loader {
  position: absolute;
  left: 50%;
  top: 187px;
  width: 1100px;
  height: 837px;
  padding-bottom: 160px;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translateX(-50%);
  transition: opacity var(--dur) var(--ease);
}
.loader img { width: 90px; height: 90px; } /* the dots animate inside loader-dots.svg */

/* ---------- Home screen parts (photo background, header with status pill, day timeline) ---------- */
.photo-bg { position: absolute; inset: 0; border-radius: 20px; background: #0f0f0f; overflow: hidden; }
.photo-bg img { position: absolute; left: -2.07%; top: -0.17%; width: 104.25%; height: 100.35%; max-width: none; opacity: 0.35; }
.frame-line { position: absolute; inset: 0; border: 4px solid; border-radius: 20px; pointer-events: none; z-index: 5; }

.home-head {
  position: absolute;
  top: 0;
  left: 0;
  width: 1366px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px 12px 24px;
  z-index: 3;
}
.home-head .left { display: flex; align-items: center; gap: 179px; flex: 1 0 0; }
.home-head .clock { height: 92px; }
.home-head .room { display: flex; align-items: center; gap: 48px; }
.home-head .room-name { height: 87px; line-height: 87px; }
.chev {
  width: 70px;
  height: 70px;
  border-radius: 106px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.4);
  -webkit-backdrop-filter: blur(17px);
  backdrop-filter: blur(17px);
}
.chev.glassy { background: var(--glass-bg); border: 2px solid var(--glass-border); }
.pill {
  min-width: 243px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 12px 36px;
  border-radius: 4px;
  font-size: 40px;
  font-weight: 800;
  line-height: normal;
  white-space: nowrap;
  color: var(--ink);
}

.timeline {
  position: absolute;
  left: 11px;
  top: 127px;
  width: 160px;
  height: 893px;
  overflow: hidden;
  border-bottom-left-radius: 8px;
}
.timeline .marker {
  position: absolute;
  left: 0;
  width: 160px;
  display: flex;
  align-items: center;
  gap: 16px;
}
.timeline .marker::before { content: ""; flex: 1 0 0; height: 1px; background: rgba(255, 255, 255, 0.65); }
.timeline .marker span { width: 81px; height: 29px; display: flex; align-items: center; font-size: 28px; font-weight: 600; line-height: 24px; }
.timeline .blk { position: absolute; left: 0; width: 60px; border-radius: 12px; display: grid; place-items: center; }
.timeline .blk.free { height: 60px; background: var(--green); }
.timeline .blk.busy { background: var(--busy); color: var(--ink); }

.meet { position: absolute; left: 390px; display: flex; flex-direction: column; gap: 86px; }
.meet-title { display: flex; flex-direction: column; gap: 8px; line-height: normal; }
.meet-title .l1, .meet-title .l2 { font-size: 72px; font-weight: 700; }
.meet-title .l3 { font-size: 64px; font-weight: 600; letter-spacing: -1px; }
.person { display: flex; align-items: center; gap: 24px; font-size: 35px; font-weight: 700; line-height: 24px; white-space: nowrap; }
.person img { width: 70px; height: 70px; border-radius: 70px; background: #fff; object-fit: cover; }
.btn-row { display: flex; align-items: center; gap: 20px; }
.btn-label { font-size: 31px; line-height: 28px; white-space: nowrap; }
.glass .plus { font-weight: 500; }

/* ---------- Tap indicator ---------- */
.tap {
  position: absolute;
  z-index: 10;
  width: 96px;
  height: 96px;
  margin: -48px 0 0 -48px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.28);
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.75);
  opacity: 0;
  transform: scale(0.6);
  pointer-events: none;
  transition: opacity 160ms ease-out, transform 220ms cubic-bezier(0, 0, 0.58, 1);
}
.tap.is-down { opacity: 1; transform: scale(1); }
/* Hands-on: the one thing that responds, and a soft pulse on it while the visitor looks for it */
.is-target { cursor: pointer; }
.is-target:focus { outline: none; }
.is-target:focus-visible { outline: 4px solid var(--focus); outline-offset: 6px; }
.tap.is-hint { animation: tap-hint 1400ms ease-out; }
@keyframes tap-hint {
  0% { opacity: 0; transform: scale(0.6); }
  25% { opacity: 0.9; transform: scale(1); }
  100% { opacity: 0; transform: scale(1.35); }
}
.tap.on-light { background: rgba(20, 25, 34, 0.18); box-shadow: 0 0 0 3px rgba(20, 25, 34, 0.6); }

/* ---------- Progress dots ---------- */
.dots { position: fixed; left: 0; right: 0; bottom: 16px; height: 28px; display: flex; align-items: center; justify-content: center; }
.dots[hidden] { display: none; }
/* Each dot is a button that jumps to its step: a 7 px dot in an 18 × 28 px hit area. */
.dots button {
  width: 18px;
  height: 28px;
  padding: 0;
  border: 0;
  background: none;
  display: grid;
  place-items: center;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.dots button::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--dot);
  transition: background-color 300ms, transform 300ms;
}
.dots button:hover::before { background: var(--dot-on); }
.dots button.on::before { background: var(--dot-on); transform: scale(1.25); }
.dots button:focus { outline: none; }
.dots button:focus-visible::before { outline: 2px solid var(--focus); outline-offset: 3px; }

@media (prefers-reduced-motion: reduce) {
  .tap { display: none; }
}
