:root {
  --bg: #f7f7f5;
  --card: #ffffff;
  --text: #1b1b1a;
  --muted: #6b6b66;
  --line: #e4e4df;
  --accent: #e8572a;
  --accent-text: #ffffff;
  --agent: #2a6fe8;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #161615;
    --card: #20201e;
    --text: #ededea;
    --muted: #a0a09a;
    --line: #34342f;
  }
}
* {
  box-sizing: border-box;
}
body {
  margin: 0 auto;
  max-width: 720px;
  padding: 24px 16px 48px;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.5 system-ui, -apple-system, "Segoe UI", sans-serif;
}
h1 {
  margin: 0;
  font-size: 28px;
  letter-spacing: -0.02em;
}
h2 {
  font-size: 15px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin: 0 0 8px;
}
section {
  margin-top: 32px;
}
.tagline,
.hint,
.empty,
footer {
  color: var(--muted);
}
.me {
  margin: 4px 0 0;
}
.peers {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 12px;
}
.peer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 18px 10px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  color: var(--text);
  font: inherit;
  cursor: pointer;
}
.peer:hover {
  border-color: var(--accent);
}
.peer.agent {
  border-color: var(--agent);
}
.peer-icon {
  font-size: 30px;
}
.peer-name {
  font-weight: 600;
  text-align: center;
  word-break: break-word;
}
.peer-room {
  font-size: 13px;
  color: var(--muted);
}
button,
input,
textarea {
  font: inherit;
  padding: 10px 14px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--text);
}
button {
  cursor: pointer;
}
button.primary {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-text);
}
button.wide {
  width: 100%;
  margin-top: 12px;
}
button:disabled {
  opacity: 0.5;
  cursor: default;
}
.code-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.code-row form {
  display: flex;
  gap: 8px;
  flex: 1;
  min-width: 240px;
}
.code-row input {
  flex: 1;
  min-width: 0;
}
.transfers {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 10px;
}
.transfer {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px 14px;
}
.t-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.t-status {
  color: var(--muted);
  font-size: 14px;
}
progress {
  width: 100%;
  height: 8px;
  margin-top: 8px;
  accent-color: var(--accent);
}
.t-files a {
  display: block;
  margin-top: 6px;
  color: var(--accent);
}
dialog {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--card);
  color: var(--text);
  max-width: min(420px, calc(100vw - 32px));
}
dialog::backdrop {
  background: rgb(0 0 0 / 0.4);
}
.in-title {
  font-weight: 600;
  margin-top: 0;
}
.in-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}
#compose button.wide {
  margin-top: 0;
}
.compose-label {
  display: block;
  margin: 16px 0 6px;
  color: var(--muted);
  font-size: 14px;
}
textarea {
  display: block;
  width: 100%;
  min-width: min(360px, calc(100vw - 80px));
  resize: vertical;
  margin-bottom: 12px;
}
.t-message {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 8px;
}
.t-message p {
  flex: 1;
  min-width: 0;
  margin: 0;
  padding: 8px 10px;
  background: var(--bg);
  border-radius: 8px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  user-select: text;
}
.t-message a {
  display: inline;
  margin: 0;
  color: var(--accent);
}
.t-message button {
  padding: 6px 12px;
  font-size: 14px;
}
.drop {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 160px;
  border: 2px dashed var(--line);
  border-radius: 16px;
  background: var(--card);
  cursor: pointer;
  text-align: center;
  padding: 16px;
}
.drop input {
  display: none;
}
.status {
  min-height: 1.5em;
}
footer {
  margin-top: 48px;
  font-size: 14px;
}
footer a {
  color: inherit;
}
.brand-line {
  margin: 0 0 4px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: -0.01em;
}
header h1 {
  font-size: 26px;
  line-height: 1.25;
}
.about {
  margin-top: 56px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
}
.about h2 {
  margin-top: 24px;
}
.about a,
.doc article a {
  color: var(--accent);
}
.foot-links a {
  white-space: nowrap;
}
code,
pre {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.92em;
}
pre {
  padding: 12px 14px;
  overflow-x: auto;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 10px;
}
.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 18px;
  align-items: baseline;
  margin-bottom: 24px;
}
.site-nav a {
  color: var(--muted);
  text-decoration: none;
}
.site-nav .brand {
  margin-right: auto;
  font-weight: 700;
  color: var(--accent);
}
.doc article h1 {
  font-size: 30px;
  line-height: 1.2;
  margin-bottom: 12px;
}
.doc article h2 {
  margin-top: 32px;
  font-size: 20px;
  text-transform: none;
  letter-spacing: -0.01em;
  color: var(--text);
}
.doc .lede {
  font-size: 18px;
}
.doc li {
  margin: 4px 0;
}
.table-wrap {
  overflow-x: auto;
  margin: 12px 0;
}
.doc table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
}
.doc th,
.doc td {
  padding: 8px 10px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}
.doc thead th {
  color: var(--muted);
  font-weight: 600;
}
.doc tbody th {
  font-weight: 600;
  min-width: 9em;
}
.checked {
  margin-top: 32px;
  color: var(--muted);
  font-size: 14px;
}
.button {
  display: inline-block;
  padding: 10px 18px;
  border-radius: 10px;
  text-decoration: none;
}
.doc .button.primary {
  background: var(--accent);
  color: var(--accent-text);
}
