:root {
  color-scheme: light;
  --ink: #1c282a;
  --sub: #51605c;
  --line: #d7ddd5;
  --page: #f5f6f0;
  --paper: #fff;
  --dark: #1d2928;
  --green: #155849;
  --accent: #eb744a;
  --faint: #e8eee5;
  --err: #a12723;
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font:
    15px/1.5 Inter,
    "Segoe UI",
    Arial,
    sans-serif;
  color: var(--ink);
  background: var(--page);
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
a,
input,
textarea,
select,
summary {
  touch-action: manipulation;
}
a {
  color: var(--green);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}
button,
.button {
  color: var(--ink);
  border: 1px solid #adbbb1;
  background: white;
  border-radius: 5px;
  padding: 0.5rem 0.85rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  font-size: 0.87rem;
  font-weight: 650;
  text-decoration: none;
}
button:hover,
.button:hover {
  background: var(--faint);
}
button:disabled {
  opacity: 0.56;
  cursor: wait;
}
.primary {
  background: var(--green);
  color: white;
  border-color: var(--green);
}
.primary:hover {
  background: #104437;
}
.quiet {
  background: transparent;
  border-color: transparent;
}
button.warn {
  color: var(--err);
}
:focus-visible {
  outline: 3px solid #428dd5;
  outline-offset: 3px;
}
.skip {
  position: fixed;
  z-index: 20;
  top: -5em;
  left: 15px;
  background: white;
  padding: 0.6em;
}
.skip:focus {
  top: 8px;
}
.startup,
.loading {
  padding: 2em;
  color: var(--sub);
}
.layout {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 226px minmax(0, 1fr);
}
.rail {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: auto;
  display: flex;
  flex-direction: column;
  background: var(--dark);
  color: #e5ece7;
  padding: 22px 14px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 700;
  letter-spacing: -0.06em;
  font-size: 1.7rem;
  line-height: 1;
  color: inherit;
  text-decoration: none;
}
.brandmark {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  height: 24px;
}
.brandmark i {
  width: 4px;
  background: var(--accent);
  height: 9px;
}
.brandmark i:nth-child(2) {
  height: 20px;
}
.brandmark i:nth-child(3) {
  height: 27px;
}
.brandmark i:nth-child(4) {
  height: 15px;
}
.rail > .brand {
  padding: 4px 12px 28px;
}
.rail nav {
  display: grid;
  gap: 3px;
}
.rail nav a {
  color: #c1cec5;
  font-size: 0.93rem;
  text-decoration: none;
  padding: 0.53rem 0.8rem;
  border-radius: 4px;
  display: flex;
  align-items: center;
  gap: 0.8rem;
}
.rail nav a:hover {
  background: #2c3b36;
}
.rail nav a[aria-current] {
  background: #35483f;
  color: #fff;
  font-weight: 650;
  border-left: 3px solid var(--accent);
  padding-left: calc(0.8rem - 3px);
}
.nav-icon {
  width: 1.35rem;
  text-align: center;
  font: 1.15rem var(--mono);
  color: #9caf9e;
}
.rail .bottom {
  margin-top: auto;
  border-top: 1px solid #46544c;
  padding: 1rem 0.7rem 0;
  display: grid;
  gap: 0.35rem;
  overflow-wrap: anywhere;
}
.bottom small {
  color: #b6c5bc;
}
.bottom button {
  background: transparent;
  border: 0;
  color: #d6e0d7;
  justify-self: start;
  padding: 0.2rem 0;
}
.workspace-shell {
  min-width: 0;
}
.topbar {
  height: 66px;
  border-bottom: 1px solid var(--line);
  padding: 0 clamp(20px, 4vw, 65px);
  display: flex;
  align-items: center;
  gap: 1rem;
  background: #fafbf6;
}
.searchbar {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex: 1;
  max-width: 500px;
}
.searchbar input {
  width: 100%;
  background: transparent;
  border: 0;
  padding: 0.45rem 0;
}
.topbar small {
  margin-left: auto;
  color: var(--sub);
}
kbd,
.tag,
.meta {
  font: 0.75rem/1.4 var(--mono);
}
kbd {
  border: 1px solid var(--line);
  padding: 0.1rem 0.35rem;
  border-radius: 3px;
  color: var(--sub);
}
.mobile-menu {
  display: none;
}
#content.main {
  max-width: 1500px;
  margin: 0 auto;
  padding: clamp(22px, 4.3vw, 62px);
  min-height: 70vh;
}
.pagehead {
  display: flex;
  gap: 1rem;
  justify-content: space-between;
  align-items: flex-end;
  margin: 0 0 2rem;
}
.pagehead h1,
.login h1 {
  font-family: "DM Sans", Inter, Arial, sans-serif;
  letter-spacing: -0.054em;
  font-size: clamp(2rem, 4.2vw, 3.7rem);
  font-weight: 620;
  line-height: 1.04;
  margin: 0;
}
.pagehead p,
.muted,
.empty,
.hint {
  color: var(--sub);
}
.pagehead p {
  margin: 0.6rem 0 0;
  max-width: 58rem;
}
.stack,
.form,
.grid,
.list,
.pair,
.settings-group {
  display: grid;
  gap: 1rem;
}
.grid {
  grid-template-columns: repeat(auto-fit, minmax(min(255px, 100%), 1fr));
  align-items: start;
}
.pair {
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.9fr);
  align-items: start;
}
.card,
.listbox,
.notice {
  border: 1px solid var(--line);
  background: var(--paper);
  border-radius: 8px;
}
.card,
.notice {
  padding: clamp(16px, 2vw, 27px);
}
.card h2,
.section-title {
  margin: 0 0 0.85rem;
  font-size: 1.15rem;
  letter-spacing: -0.025em;
}
.card h3 {
  font-size: 1rem;
  margin: 0;
}
.row,
.toolbar,
.tabs {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.6rem;
}
.toolbar {
  justify-content: space-between;
  margin-bottom: 1rem;
}
.tabs {
  border-bottom: 1px solid var(--line);
  gap: 1rem;
  margin-bottom: 1.25rem;
}
.tabs button {
  border: 0;
  border-radius: 0;
  padding: 0.55rem 0.25rem;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: var(--sub);
}
.tabs button[aria-pressed="true"] {
  border-color: var(--green);
  color: var(--ink);
}
.tag {
  display: inline-block;
  background: #e8eee7;
  color: #305749;
  padding: 0.12rem 0.43rem;
  border-radius: 4px;
  overflow-wrap: anywhere;
}
.meta {
  color: var(--sub);
  overflow-wrap: anywhere;
}
.record {
  display: grid;
  gap: 0.42rem;
  padding: 1rem 1.2rem;
  border-bottom: 1px solid var(--line);
  min-width: 0;
}
.record:last-child {
  border: 0;
}
.record .title {
  color: var(--ink);
  font-weight: 640;
  font-size: 1rem;
  text-decoration: none;
}
.record .title:hover {
  text-decoration: underline;
}
.record p {
  margin: 0;
  color: var(--sub);
  font-size: 0.92rem;
}
.field {
  display: grid;
  gap: 0.28rem;
  min-width: 0;
  font-weight: 600;
  font-size: 0.84rem;
}
.field input,
.field select,
.field textarea {
  font-weight: 400;
  color: var(--ink);
  border: 1px solid #b9c4ba;
  width: 100%;
  padding: 0.57rem 0.65rem;
  border-radius: 4px;
  background: #fff;
}
.field textarea {
  min-height: 6em;
  resize: vertical;
}
.field.code textarea,
pre,
code {
  font-family: var(--mono);
  font-size: 0.82rem;
}
.fields {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(154px, 100%), 1fr));
  gap: 0.8rem;
}
.form small,
.hint {
  font-size: 0.84rem;
  font-weight: 400;
}
.form .actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}
.form button {
  justify-self: start;
}
.notice {
  padding: 0.75rem 1rem;
}
.error {
  border-color: #e5bbb8;
  background: #fff4f3;
  color: var(--err);
}
.success {
  background: #eef6ed;
  color: var(--green);
}
.empty {
  padding: 1.15rem;
  border: 1px dashed #bac6bb;
  border-radius: 5px;
}
.empty strong {
  display: block;
  color: var(--ink);
}
details {
  min-width: 0;
}
summary {
  cursor: pointer;
  color: var(--green);
  font-weight: 600;
}
pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  background: #f2f5ef;
  border-radius: 5px;
  padding: 0.85rem;
  max-height: 28em;
  overflow: auto;
}
dl.data {
  display: grid;
  grid-template-columns: minmax(90px, auto) 1fr;
  gap: 0;
  margin: 0;
}
dl.data dt,
dl.data dd {
  border-bottom: 1px solid var(--line);
  padding: 0.5rem 0;
  overflow-wrap: anywhere;
}
dl.data dt {
  color: var(--sub);
  padding-right: 0.75rem;
}
dl.data dd {
  margin: 0;
}
.credentials {
  display: grid;
  gap: 1rem;
}
.login {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(280px, 0.82fr) minmax(370px, 1fr);
}
.login aside {
  background: var(--dark);
  color: white;
  display: flex;
  flex-direction: column;
  gap: 3rem;
  justify-content: space-between;
  padding: clamp(32px, 6vw, 90px);
  overflow: hidden;
}
.login aside p {
  font-size: 1.7rem;
  font-weight: 500;
  letter-spacing: -0.035em;
  max-width: 17rem;
  line-height: 1.2;
  color: #deeadf;
}
.login main {
  display: grid;
  align-content: center;
  justify-content: center;
  padding: clamp(24px, 5vw, 80px);
}
.login main > section {
  width: min(100%, 430px);
}
.login .meta {
  overflow-wrap: anywhere;
}
.login .tabs {
  margin-top: 2.2rem;
}
.login h1 {
  font-size: clamp(2rem, 5vw, 3.3rem);
}
.login .form button {
  width: 100%;
  padding: 0.75em;
}
.wave {
  height: 110px;
  display: flex;
  align-items: center;
  gap: 2%;
  margin: 2rem 0;
}
.wave i {
  width: 2.7%;
  height: 33%;
  background: var(--accent);
}
.wave i:nth-child(3n) {
  height: 70%;
}
.wave i:nth-child(5n) {
  height: 96%;
}
.wave i:nth-child(4n) {
  height: 48%;
}
.wave i:nth-child(7n) {
  height: 22%;
}
.secret {
  user-select: all;
}
.topic-list {
  display: grid;
  gap: 0.35em;
  list-style: none;
  padding-left: 1.15em;
  border-left: 1px solid var(--line);
}
.chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4em;
}
.dialog-close {
  float: right;
}
dialog {
  max-width: min(94vw, 680px);
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 1.5rem;
  color: var(--ink);
}
dialog::backdrop {
  background: #1b272780;
}
input[type="checkbox"] {
  width: auto;
}
.inline-input {
  width: 100%;
}
.stream-title {
  margin: 0;
  font-weight: 600;
}
hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 1rem 0;
}
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
}
@media (max-width: 850px) {
  .layout {
    grid-template-columns: 178px minmax(0, 1fr);
  }
  .pair {
    grid-template-columns: 1fr;
  }
  .rail {
    padding: 16px 9px;
  }
}
@media (max-width: 650px) {
  .layout,
  .login {
    display: block;
  }
  .rail {
    display: none;
    position: fixed;
    width: min(280px, 88vw);
    z-index: 6;
    box-shadow: 12px 0 54px #18252155;
  }
  .layout.open .rail {
    display: flex;
  }
  .mobile-menu {
    display: inline-flex;
  }
  .topbar {
    padding: 0 15px;
    height: 55px;
  }
  .topbar small,
  kbd {
    display: none;
  }
  .pagehead {
    align-items: flex-start;
    flex-direction: column;
  }
  .login aside {
    padding: 24px;
  }
  .login aside p,
  .login .wave {
    display: none;
  }
  .login main {
    padding: 35px 20px;
    justify-content: stretch;
  }
  .login main > section {
    margin: 0 auto;
  }
  .login aside > .brand {
    padding: 0;
  }
  .pagehead h1 {
    font-size: 2.3rem;
  }
  #content.main {
    padding: 24px 15px;
  }
  .card {
    padding: 16px;
  }
  .fields {
    grid-template-columns: 1fr;
  }
}

.neighborhood-map {
  margin: 0;
  padding: 0.75rem;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--page);
}
.neighborhood-map canvas {
  display: block;
  width: 100%;
  height: auto;
}
