/* The host owns viewport geometry; Flutter receives the real inner screen size. */
:root {
  color-scheme: light;
  --desktop-gap: clamp(8px, 1.8vmin, 24px);
  --tablet-bezel: clamp(8px, 1.1vmin, 12px);
  --tablet-radius: clamp(26px, 4.5vmin, 42px);
}

html, body, .tablet-frame, .tablet-screen, #flutter-host, #startup-status {
  box-sizing: border-box;
}

html, body {
  width: 100%;
  height: 100%;
  margin: 0;
  overflow: hidden;
}

body {
  height: 100vh;
  height: 100dvh;
  padding: var(--desktop-gap);
  background: #e8eaee;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.tablet-frame {
  position: relative;
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  padding: var(--tablet-bezel);
  border: 1px solid #45484e;
  border-radius: var(--tablet-radius);
  background: #202226;
  box-shadow: 0 12px 32px #1b202b26, inset 0 0 0 1px #101114;
}

.tablet-frame::before {
  content: "";
  position: absolute;
  top: calc(var(--tablet-bezel) / 2 - 1px);
  left: 50%;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #56616f;
  transform: translateX(-50%);
  pointer-events: none;
}

.tablet-screen {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: calc(var(--tablet-radius) - var(--tablet-bezel));
  overflow: hidden;
  isolation: isolate;
  background: #f5f6f8;
}

#flutter-host {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: inherit;
}

#startup-status {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  color: #252633;
  background: #f5f6f8;
  font-size: 14px;
  text-align: center;
}

@media (max-width: 480px), (max-height: 480px) {
  :root {
    --desktop-gap: 5px;
    --tablet-bezel: 7px;
    --tablet-radius: 25px;
  }
}

/* Owner Web uses the actual viewport; member presentation above stays unchanged. */
.owner-entry body { padding: 0; background: #f5f6f8; }
.owner-entry .tablet-frame { padding: 0; border: 0; border-radius: 0; box-shadow: none; background: transparent; }
.owner-entry .tablet-frame::before { display: none; }
.owner-entry .tablet-screen { border-radius: 0; }
