:root {
  color-scheme: dark;
  --bg: #0f1115;
  --panel: #1a1d24;
  --border: #2a2e37;
  --text: #e6e8eb;
  --muted: #8a8f99;
  --accent: #4f8cff;
  --danger: #ff5c5c;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
}

.screen {
  height: 100vh;
  width: 100vw;
  display: flex;
  align-items: center;
  justify-content: center;
}

.screen.hidden { display: none; }

#login-form {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 32px;
  width: 320px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

#login-form h1 {
  margin: 0 0 8px 0;
  font-size: 22px;
}

#login-form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  color: var(--muted);
}

#login-form .hint { font-size: 11px; }

#login-form input {
  background: #0f1115;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 12px;
  color: var(--text);
  font-size: 15px;
}

#login-form button {
  background: var(--accent);
  border: none;
  border-radius: 8px;
  padding: 12px;
  color: white;
  font-size: 15px;
  cursor: pointer;
}

#login-form button:hover { opacity: 0.9; }

.status {
  min-height: 18px;
  font-size: 13px;
  color: var(--danger);
  margin: 0;
}

#remote-screen {
  flex-direction: column;
  background: black;
}

#toolbar {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 16px;
  background: var(--panel);
  border-bottom: 1px solid var(--border);
  font-size: 13px;
  color: var(--muted);
}

#toolbar button {
  background: var(--danger);
  border: none;
  border-radius: 6px;
  padding: 6px 12px;
  color: white;
  cursor: pointer;
}

#remote-video {
  flex: 1;
  width: 100%;
  height: calc(100vh - 41px);
  object-fit: contain;
  background: black;
  cursor: none;
}
