:root {
  color-scheme: dark;
  font-family: system-ui, sans-serif;
  background: #111;
  color: #f5f5f5;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100dvh;
}

button {
  padding: 0.5rem 0.75rem;
  border: 1px solid #777;
  border-radius: 0.4rem;
  background: #292929;
  color: inherit;
  cursor: pointer;
}

.landing {
  display: grid;
  min-height: 100dvh;
  place-content: center;
  justify-items: center;
  padding: 2rem;
}

.landscape-split,
.spectator {
  display: flex;
  min-height: 100dvh;
  flex-direction: column;
}

.chrome {
  display: flex;
  min-height: 3rem;
  align-items: center;
  gap: 1rem;
  padding: 0.5rem 1rem;
  background: #151719;
}

#status {
  color: #ffb4ab;
}

.split {
  display: flex;
  min-height: 0;
  flex: 1;
  flex-direction: row;
}

.pane {
  position: relative;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  background: #1e2326;
}

.split > .pane {
  flex: 0 0 50%;
}

.video-pane {
  background: #050505;
}

#video,
#view {
  display: block;
  width: 100%;
  height: 100%;
}

#video {
  object-fit: cover;
}

.stub-label {
  position: absolute;
  right: 0.6rem;
  bottom: 0.6rem;
  left: 0.6rem;
  margin: 0;
  padding: 0.35rem 0.55rem;
  border-radius: 0.3rem;
  background: rgb(0 0 0 / 55%);
  font-size: 0.75rem;
  pointer-events: none;
}

#view {
  touch-action: none;
  cursor: grab;
}


.spectator-view {
  display: flex;
  min-height: 0;
  flex: 1;
}

.spectator-view .view-pane {
  flex: 1;
}

@media (orientation: portrait) {
  .landscape-split::after {
    position: fixed;
    inset: 0;
    z-index: 10;
    display: grid;
    place-content: center;
    padding: 2rem;
    background: #111;
    content: "Rotate your device to landscape";
    text-align: center;
  }
}
