:root {
  color-scheme: dark;
  --bg: #161917;
  --side: #1b1e1b;
  --panel: #222622;
  --line: #323730;
  --muted: #a2a99f;
  --lime: #b9ed8a;
  --text: #edf0e9;
  --mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-family: "Inter", "Segoe UI", Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  min-width: 300px;
}
button,
input,
textarea,
select {
  font: inherit;
}
button,
a {
  color: inherit;
}
button {
  cursor: pointer;
  background: none;
  border: 0;
}
button:focus-visible,
a:focus-visible,
textarea:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 2px solid var(--lime);
  outline-offset: 3px;
}
button:disabled {
  opacity: 0.55;
  cursor: wait;
}
svg {
  width: 19px;
  height: 19px;
  display: block;
  stroke: currentColor;
  stroke-width: 1.65;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}
i {
  font-style: normal;
  display: inline-flex;
}
h1,
h2,
h3,
p {
  margin: 0;
}
.top {
  height: 64px;
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--line);
  padding: 0 24px;
  gap: 28px;
  background: #171a17;
}
.brand {
  display: flex;
  align-items: center;
  text-decoration: none;
  font-size: 32px;
  font-weight: 750;
  letter-spacing: -1.9px;
  gap: 8px;
}
.brand img {
  width: 33px;
}
.brand span {
  margin-left: -8px;
  color: var(--lime);
}
.crumb {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  font-size: 13px;
  border-left: 1px solid var(--line);
  padding-left: 25px;
}
.crumb i svg {
  width: 16px;
}
.crumb strong {
  font-weight: 550;
  color: #d8ddd4;
}
.crumb b {
  font-weight: 400;
  color: #697063;
}
.status {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 8px;
  font: 12px var(--mono);
  color: #c6d6bd;
  background: #232b22;
  border: 1px solid #374534;
  padding: 6px 10px;
  border-radius: 20px;
}
.status em {
  width: 6px;
  height: 6px;
  background: var(--lime);
  border-radius: 50%;
}
.layout {
  height: calc(100dvh - 64px);
  display: grid;
  grid-template-columns: 244px minmax(0, 1fr) 272px;
  overflow: hidden;
}
.sidebar {
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--line);
  background: var(--side);
  min-height: 0;
  padding: 20px 15px 0;
  overflow-y: auto;
}
.station {
  height: 139px;
  flex-shrink: 0;
  position: relative;
  overflow: hidden;
  padding: 16px;
  border: 1px solid #445237;
  border-radius: 9px;
  background: #293225;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.station canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.station div,
.station-icon {
  position: relative;
}
.station-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  background: var(--lime);
  color: #263222;
  border-radius: 7px;
}
.station-icon svg {
  width: 25px;
  height: 25px;
}
.station small,
.navgroup h3,
.context h3,
.day,
.hint,
.stamp,
.fileline small,
.account small,
.sidebar-foot small,
.dialog-label,
#modal-kicker,
.count,
.role {
  font-family: var(--mono);
}
.station small,
#modal-kicker {
  font-size: 11px;
  letter-spacing: 1.6px;
  color: #cad7be;
}
.station h2 {
  font-size: 23px;
  letter-spacing: -0.9px;
  margin-top: 3px;
}
.navgroup {
  margin-top: 26px;
}
.navgroup h3,
.context h3 {
  display: flex;
  align-items: center;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  font-size: 11.5px;
  line-height: 24px;
  color: #a9afa4;
  font-weight: 600;
}
.navgroup h3 {
  padding: 0 10px;
  margin: 0 0 6px;
}
.navgroup .nav,
.channel {
  display: flex;
  align-items: center;
  text-align: left;
  width: 100%;
  border-radius: 6px;
  color: #bbc1b6;
  gap: 12px;
  padding: 9px 11px;
  min-height: 37px;
  font-size: 14px;
}
.nav:hover,
.channel:hover,
.icon:hover,
.member:hover,
.textbtn:hover,
.account:hover,
#usage:hover {
  background: #2b302a;
  color: #eee;
}
.channel.current {
  color: var(--lime);
  background: #303c2a;
  font-weight: 600;
}
.channel.current::after {
  content: "";
  width: 6px;
  height: 6px;
  margin-left: auto;
  border-radius: 50%;
  background: var(--lime);
}
.channel b {
  line-height: 1;
  font: 21px var(--mono);
  color: #8b9586;
}
.channel.current b {
  color: var(--lime);
}
.nav i {
  color: #a6b09f;
}
.icon {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  color: var(--muted);
}
.navgroup h3 .icon,
.context header .icon {
  margin-left: auto;
}
.sidebar-foot {
  margin-top: auto;
  padding-top: 30px;
}
.sidebar-foot small {
  color: #99a392;
  font-size: 11.5px;
}
#usage {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 9px 4px;
  width: 100%;
  padding: 14px 12px;
  text-align: left;
  font-size: 13px;
  border: 1px solid var(--line);
  border-radius: 7px;
}
#usage span,
.hint span,
.fileline > div,
.context h3 {
  display: flex;
  align-items: center;
  gap: 8px;
}
#usage svg,
.hint svg {
  width: 15px;
  height: 15px;
}
.meter {
  grid-column: 1/-1;
  height: 4px;
  border-radius: 4px;
  background: #363e32;
  overflow: hidden;
  display: block;
}
.meter i {
  background: var(--lime);
  height: 100%;
  display: block;
}
.account {
  width: calc(100% + 30px);
  margin: 15px -15px 0;
  padding: 15px 18px;
  display: flex;
  gap: 10px;
  align-items: center;
  text-align: left;
  border-top: 1px solid var(--line);
}
.account small,
.account strong {
  display: block;
}
.account strong {
  font-size: 14px;
  margin-bottom: 3px;
}
.account > i {
  margin-left: auto;
  color: #a3ac9c;
}
main {
  min-width: 0;
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.room,
.context header {
  height: 78px;
  flex-shrink: 0;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
}
.room {
  padding: 0 26px;
  gap: 13px;
}
.hashbox {
  width: 41px;
  height: 41px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  border: 1px solid #3c4935;
  background: #283124;
  color: var(--lime);
  font: 27px var(--mono);
}
.room h1 {
  font-size: 23px;
  letter-spacing: -0.8px;
}
.room p {
  font-size: 13px;
  color: var(--muted);
  margin-top: 3px;
}
.tools {
  margin-left: auto;
  display: flex;
  gap: 6px;
}
.icon.on {
  color: var(--lime);
  background: #293125;
}
.context {
  border-left: 1px solid var(--line);
  background: #191c19;
  overflow-y: auto;
}
.context header {
  padding: 0 20px;
  justify-content: space-between;
  font-size: 16px;
  font-weight: 650;
}
.context-body {
  padding: 0 20px;
}
.context-body section {
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
}
.context-body section:last-child {
  border: 0;
}
.context h3 {
  margin-bottom: 14px;
}
.context h3 > i svg {
  width: 15px;
  height: 15px;
}
.pin {
  padding: 13px 14px;
  background: #252b23;
  border: 1px solid #3c4736;
  border-radius: 7px;
  width: 100%;
  text-align: left;
}
.pin small {
  display: flex;
  align-items: center;
  gap: 7px;
  font: 11.5px var(--mono);
  color: var(--lime);
  margin-bottom: 8px;
}
.pin p {
  font-size: 14px;
  line-height: 1.5;
  color: #d8ded3;
}
.pin time {
  display: block;
  font: 11px var(--mono);
  color: #a1aa99;
  margin-top: 10px;
}
.textbtn {
  margin-left: auto;
  color: var(--lime);
  font-size: 12px;
  letter-spacing: 0;
  font-family: Arial, sans-serif;
}
.thumbs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
}
.thumbs button {
  min-width: 0;
  padding: 0;
  border-radius: 5px;
  overflow: hidden;
  background: #2f342e;
}
.thumbs img {
  width: 100%;
  height: 74px;
  object-fit: cover;
  display: block;
}
.count {
  color: #b0b9a9;
  font-size: 11px;
  padding: 0 6px;
  background: #2b3029;
  border-radius: 4px;
  line-height: 17px;
}
.member {
  display: flex;
  gap: 10px;
  align-items: center;
  text-align: left;
  width: 100%;
  padding: 6px 0;
  font-size: 14px;
}
.role {
  margin-left: auto;
  color: #b3bfa9;
  font-size: 10px;
  letter-spacing: 0.3px;
  padding: 3px 5px;
  border: 1px solid #3a4435;
  border-radius: 4px;
}
.avatar {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 37px;
  height: 37px;
  border-radius: 9px;
}
.avatar svg {
  width: 75%;
  height: 75%;
  stroke: none;
}
.member .avatar,
.account .avatar {
  width: 31px;
  height: 31px;
  border-radius: 7px;
}
#timeline {
  min-height: 0;
  overflow-y: auto;
  flex: 1;
  scrollbar-width: thin;
  scrollbar-color: #40463e transparent;
  overscroll-behavior: contain;
}
#messages {
  padding: 4px 26px 15px;
}
.day {
  display: flex;
  gap: 12px;
  align-items: center;
  font-size: 11.5px;
  color: #9ba594;
  justify-content: center;
  margin: 18px 0 21px;
}
.day:before,
.day:after {
  content: "";
  height: 1px;
  flex: 1;
  background: var(--line);
}
.message {
  position: relative;
  display: flex;
  gap: 12px;
  margin-bottom: 21px;
  min-width: 0;
  scroll-margin-top: 12px;
}
.message:last-child {
  margin-bottom: 0;
}
.message-body {
  min-width: 0;
  flex: 1;
}
.by {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 21px;
}
.by strong {
  font-size: 15px;
  letter-spacing: -0.15px;
}
.stamp {
  font-size: 11px;
  color: #9ca398;
}
.msgtext {
  font-size: 15px;
  line-height: 1.55;
  color: #d4d9d0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  margin: 3px 0;
}
.attachment {
  margin-top: 9px;
  max-width: 520px;
  border: 1px solid #394035;
  border-radius: 9px;
  overflow: hidden;
  background: #20241f;
}
.attachment > button {
  width: 100%;
  display: block;
  padding: 0;
}
.attachment img,
.attachment video {
  display: block;
  width: 100%;
  max-height: 240px;
  object-fit: cover;
}
.fileline {
  display: flex;
  padding: 9px 12px;
  align-items: center;
  gap: 10px;
  line-height: 1.2;
}
.fileline i {
  color: #a9b5a1;
}
.fileline span {
  font: 12px var(--mono);
  overflow: hidden;
  text-overflow: ellipsis;
}
.fileline small {
  margin-left: auto;
  font-size: 11px;
  color: #a0a99a;
}
.reactions {
  display: flex;
  gap: 5px;
  margin-top: 7px;
  align-items: center;
}
.react,
.chiplike {
  display: flex;
  align-items: center;
  gap: 6px;
  border: 1px solid #394136;
  border-radius: 6px;
  background: #252b23;
  color: #cbd1c6;
  font: 12px var(--mono);
  padding: 4px 8px;
}
.react.mine {
  background: #304229;
  border-color: #637c52;
  color: var(--lime);
}
.actions {
  position: absolute;
  top: -12px;
  right: 0;
  display: flex;
  opacity: 0;
  background: #262b25;
  border: 1px solid #40493c;
  border-radius: 6px;
}
.actions .icon {
  width: 28px;
  height: 26px;
}
.actions svg {
  width: 15px;
}
.message:hover .actions,
.message:focus-within .actions {
  opacity: 1;
}
.composewrap {
  padding: 10px 25px 14px;
}
.composewrap form {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #232722;
  border: 1px solid #40463c;
  border-radius: 9px;
  padding: 10px;
}
.composewrap form:focus-within {
  border-color: #678258;
}
.attach {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  background: #343b30;
  border: 1px solid #46503f;
  border-radius: 6px;
  color: #c7cec0;
}
textarea {
  flex: 1;
  min-width: 0;
  background: none;
  border: 0;
  color: var(--text);
  padding: 5px 0;
  resize: none;
  max-height: 100px;
  font-size: 15px;
}
textarea:focus-visible {
  outline: none;
}
.send {
  background: var(--lime);
  color: #23301b;
  border-radius: 6px;
  width: 34px;
  height: 33px;
  display: grid;
  place-items: center;
}
.send svg {
  width: 16px;
}
.hint {
  margin: 9px 2px 0;
  display: flex;
  justify-content: space-between;
  font-size: 10.5px;
  color: #99a291;
}
.hint svg {
  width: 12px;
  height: 12px;
}
kbd {
  font-family: inherit;
  color: #b4bbae;
}
.empty {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.6;
}
.mobile-only {
  display: none;
}
body.no-context .layout {
  grid-template-columns: 244px minmax(0, 1fr);
}
body.no-context .context {
  display: none;
}
#filter {
  padding: 8px 20px;
  display: flex;
  align-items: center;
  gap: 8px;
  background: #20251f;
}
#filter input {
  flex: 1;
}
#filter[hidden] {
  display: none;
}
dialog {
  color: var(--text);
  background: #1f241e;
  border: 1px solid #485240;
  border-radius: 13px;
  width: min(520px, 93vw);
  max-height: 85dvh;
  padding: 22px;
  box-shadow: 0 22px 80px #0007;
}
dialog::backdrop {
  background: #070a08bf;
}
dialog > header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}
dialog h2 {
  font-size: 24px;
  letter-spacing: -0.8px;
  margin-top: 4px;
}
#modal-kicker {
  color: var(--lime);
}
.layout-form {
  display: grid;
  gap: 15px;
}
.layout-form label {
  display: grid;
  gap: 7px;
  font-size: 14px;
  color: #d6ddcf;
}
input,
select {
  min-width: 0;
  background: #151914;
  color: var(--text);
  border: 1px solid #414a3b;
  border-radius: 6px;
  padding: 10px 12px;
}
input[type="file"] {
  width: 100%;
}
input[type="checkbox"] {
  accent-color: var(--lime);
}
.layout-form .check {
  display: flex;
  align-items: center;
  gap: 8px;
}
.primary,
.secondary,
.danger,
.load {
  padding: 9px 13px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 14px;
}
.primary {
  background: var(--lime);
  color: #26331f;
}
.secondary,
.load {
  background: #30372c;
  color: #d5dece;
  border: 1px solid #414c3b;
}
.danger {
  background: #44302a;
  color: #ffd1bc;
}
.load {
  display: block;
  margin: 12px auto;
}
.settings-list {
  display: grid;
  gap: 8px;
}
.settings-list > button,
.library-row {
  display: flex;
  gap: 12px;
  align-items: center;
  text-align: left;
  padding: 12px;
  background: #282e26;
  border: 1px solid #3b4436;
  border-radius: 7px;
}
.settings-list > button > i:last-child {
  margin-left: auto;
}
.library-row {
  margin: 8px 0;
}
.library-row .info {
  flex: 1;
  min-width: 0;
}
.info strong,
.info small {
  display: block;
  overflow-wrap: anywhere;
}
.info small {
  font: 12px var(--mono);
  color: var(--muted);
  margin-top: 4px;
}
.library-row img {
  width: 60px;
  height: 45px;
  object-fit: cover;
  border-radius: 5px;
}
.lightbox {
  display: block;
  width: 100%;
  border-radius: 7px;
  max-height: 60vh;
  object-fit: contain;
}
.choices {
  display: flex;
  gap: 9px;
  flex-wrap: wrap;
}
.choices button {
  padding: 10px;
  background: #30372d;
  border-radius: 8px;
  font-size: 24px;
}
#toast {
  position: fixed;
  bottom: 26px;
  left: 50%;
  transform: translateX(-50%);
  max-width: 90vw;
  z-index: 12;
  background: #e1edda;
  color: #21301b;
  padding: 10px 16px;
  font-size: 14px;
  border-radius: 7px;
  box-shadow: 0 4px 20px #0005;
}
#toast:empty {
  display: none;
}
.feedback {
  color: #ffc1a9;
  font-size: 14px;
  line-height: 1.5;
}
.account-settings {
  margin: 12px 0;
  font-size: 14px;
  line-height: 1.5;
  color: var(--muted);
}
button:hover {
  filter: brightness(1.07);
}
@media (min-width: 1550px) {
  .layout {
    grid-template-columns: 265px minmax(0, 1fr) 300px;
  }
  #messages {
    padding-left: 36px;
    padding-right: 36px;
  }
  .attachment {
    max-width: 570px;
  }
}
@media (max-width: 1150px) {
  .layout {
    grid-template-columns: 211px minmax(0, 1fr) 225px;
  }
  .context-body {
    padding: 0 15px;
  }
  .room {
    padding: 0 18px;
  }
  #messages {
    padding-left: 18px;
    padding-right: 18px;
  }
  .composewrap {
    padding-left: 16px;
    padding-right: 16px;
  }
  .station {
    height: 120px;
  }
  body.no-context .layout {
    grid-template-columns: 211px minmax(0, 1fr);
  }
}
@media (max-width: 950px) {
  .layout,
  body.no-context .layout {
    grid-template-columns: 205px minmax(0, 1fr);
  }
  .context {
    display: none;
  }
  body.details-open .context {
    display: block;
    position: fixed;
    z-index: 5;
    right: 0;
    top: 64px;
    bottom: 0;
    width: 265px;
    box-shadow: -20px 0 50px #0006;
  }
  .station {
    height: 123px;
  }
  .attachment img {
    max-height: 225px;
  }
}
@media (max-width: 640px) {
  .top {
    height: 52px;
    padding: 0 14px;
    gap: 12px;
  }
  .brand {
    font-size: 26px;
  }
  .brand img {
    width: 27px;
  }
  .crumb {
    font-size: 0;
    gap: 0;
    padding-left: 12px;
  }
  .crumb i,
  .crumb b {
    display: none;
  }
  .crumb strong {
    font-size: 13px;
  }
  .status {
    font-size: 10px;
  }
  .layout,
  body.no-context .layout {
    height: calc(100dvh - 52px);
    display: flex;
  }
  .sidebar {
    display: none;
  }
  body.nav-open .sidebar {
    display: flex;
    position: fixed;
    z-index: 6;
    top: 0;
    bottom: 0;
    left: 0;
    width: 255px;
    box-shadow: 20vw 0 0 100vw #0008;
  }
  main {
    width: 100%;
  }
  .mobile-only {
    display: grid;
  }
  #close-nav {
    align-self: flex-end;
    margin-bottom: 7px;
  }
  .room {
    height: 65px;
    padding: 0 10px;
    gap: 8px;
  }
  .room h1 {
    font-size: 19px;
  }
  .room p {
    font-size: 12px;
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
  }
  .room-name {
    min-width: 0;
  }
  .hashbox {
    display: none;
  }
  .tools {
    gap: 1px;
  }
  .message {
    gap: 9px;
  }
  .avatar {
    width: 31px;
    height: 31px;
  }
  .msgtext {
    font-size: 15px;
  }
  .composewrap {
    padding: 8px 10px 9px;
  }
  .context {
    top: 52px !important;
  }
  .hint {
    font-size: 10px;
  }
  #messages {
    padding: 3px 12px 12px;
  }
  .composewrap form {
    gap: 6px;
  }
  .attachment img {
    max-height: 200px;
  }
  .actions {
    opacity: 1;
    position: static;
    border: 0;
    background: none;
    float: right;
  }
  .actions .icon {
    width: 23px;
    height: 19px;
  }
  .actions svg {
    width: 13px;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto !important;
  }
}
.attachment {
  max-width: 570px;
}
.attachment img {
  aspect-ratio: 2.4 / 1;
  height: auto;
  object-fit: cover;
}
.choices .danger,
.choices .secondary {
  font-size: 14px;
}
.pin small svg {
  width: 13px;
  height: 13px;
}

.audio-setup fieldset {
  display: grid;
  gap: 12px;
  min-width: 0;
  margin: 0;
  padding: 13px 16px 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.audio-setup legend {
  color: var(--lime);
  padding: 0 6px;
  font-weight: 600;
}
.audio-options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
}
.audio-setup meter,
.audio-setup input[type="range"] {
  width: 100%;
  accent-color: var(--lime);
}
.audio-setup input[type="range"] {
  padding: 0;
  margin: 0;
}
.audio-note {
  font-size: 13px;
  line-height: 1.45;
  color: var(--muted);
}
.audio-note:empty {
  display: none;
}
.audio-setup label[for="audio-volume"] {
  display: flex;
  justify-content: space-between;
}
.audio-setup output {
  font: 13px var(--mono);
}

.voice-button {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 5px 8px;
  color: var(--muted);
  font-size: 13px;
  border: 1px solid var(--line);
  border-radius: 6px;
}
.voice-button.on {
  color: var(--lime);
  background: #283124;
}
.voice-button svg {
  width: 16px;
  height: 16px;
}
.voice-actions {
  display: flex;
  gap: 8px;
  margin-top: 15px;
}
.listener-settings {
  border: 1px solid var(--line);
  border-radius: 7px;
  display: grid;
  gap: 12px;
  padding: 14px;
  margin: 0 0 16px;
}
.listener-settings legend {
  color: var(--lime);
  padding: 0 6px;
}
.listener-settings label {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 14px;
}
.listener-settings output {
  margin-left: auto;
  font: 13px var(--mono);
}
.listener-settings input[type="range"] {
  width: 100%;
  padding: 0;
  accent-color: var(--lime);
}
@media (max-width: 640px) {
  .voice-button span {
    display: none;
  }
}

/* Personal reading preferences apply to both live messages and the settings sample. */
:root[data-theme="midnight"] {
  --bg: #111925;
  --side: #182230;
  --panel: #202d3d;
  --line: #354252;
  --lime: #9acdf6;
  --text: #eaf2fa;
  --muted: #a9baca;
}
:root[data-theme="plum"] {
  --bg: #211923;
  --side: #291f2b;
  --panel: #352739;
  --line: #503c51;
  --lime: #efb4de;
  --text: #f6edf4;
  --muted: #c8adc3;
}
:root[data-theme="contrast"] {
  --bg: #090909;
  --side: #101010;
  --panel: #191919;
  --line: #747474;
  --lime: #ffed85;
  --text: #fff;
  --muted: #ddd;
}
:root[data-font="humanist"] {
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
}
:root[data-font="serif"] {
  font-family: Georgia, "Times New Roman", serif;
}
:root[data-font="mono"] {
  font-family: var(--mono);
}
.msgtext {
  font-size: var(--chat-size, 0.9375rem);
}
:root[data-spacing="compact"] .message {
  margin-bottom: 9px;
  gap: 8px;
}
:root[data-spacing="compact"] .msgtext {
  line-height: 1.3;
}
:root[data-spacing="relaxed"] .message {
  margin-bottom: 32px;
  gap: 17px;
}
:root[data-spacing="relaxed"] .msgtext {
  line-height: 1.8;
}
:root:is([data-theme="midnight"], [data-theme="plum"], [data-theme="contrast"])
  :is(.top, .context, dialog) {
  background: var(--side);
}
:root:is([data-theme="midnight"], [data-theme="plum"], [data-theme="contrast"])
  :is(
    .pin,
    .hashbox,
    .attachment,
    .composewrap form,
    .channel.current,
    .settings-list > button,
    .setting-row,
    input,
    select,
    .settings-shell nav button[aria-current]
  ) {
  background: var(--panel);
  border-color: var(--line);
}
:root:is([data-theme="midnight"], [data-theme="plum"], [data-theme="contrast"])
  .msgtext {
  color: var(--text);
}
dialog:has(.settings-shell) {
  width: min(780px, 95vw);
}
.settings-shell {
  display: grid;
  grid-template-columns: 165px minmax(0, 1fr);
  gap: 23px;
}
.settings-shell nav {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 4px;
  border-right: 1px solid var(--line);
  padding-right: 13px;
}
.settings-shell nav button {
  text-align: left;
  padding: 9px 10px;
  border-radius: 6px;
  color: var(--muted);
  font-size: 14px;
}
.settings-shell nav button[aria-current] {
  color: var(--lime);
  background: #303b2b;
}
.settings-shell section {
  min-width: 0;
}
.settings-shell section h3 {
  font-size: 19px;
  margin-bottom: 16px;
}
.setting-row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  text-align: left;
  border: 1px solid var(--line);
  background: var(--panel);
  padding: 11px 13px;
  border-radius: 7px;
}
.setting-row small {
  display: block;
  color: var(--muted);
  margin-top: 4px;
}
.setting-row > span:last-child {
  color: var(--lime);
}
.setting-checks {
  display: grid;
  gap: 9px;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 13px;
}
.setting-checks legend,
.settings-back {
  color: var(--lime);
  font-size: 13px;
}
.settings-back {
  text-align: left;
  padding: 0;
}
.settings-shell [hidden] {
  display: none !important;
}
.effective {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.55;
}
.effective summary {
  cursor: pointer;
  color: var(--text);
}
.appearance-sample {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--bg);
}
.settings-shell input[type="range"] {
  padding: 0;
  accent-color: var(--lime);
}
#channel-audience > * {
  margin-bottom: 10px;
}
.expression-icon {
  max-width: 1.65em;
  max-height: 1.5em;
  object-fit: contain;
  vertical-align: middle;
}
.msgtext .expression-sticker {
  display: inline-block;
  max-width: min(175px, 100%);
  max-height: 145px;
  object-fit: contain;
  vertical-align: middle;
  border-radius: 5px;
}
.choices .expression-choice {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
}
.expression-choice img {
  width: 36px;
  height: 36px;
  object-fit: contain;
}
.member .role {
  max-width: 92px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
@media (max-width: 640px) {
  .settings-shell {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  .settings-shell nav {
    flex-direction: row;
    flex-wrap: wrap;
    border: 0;
    padding: 0;
  }
  .settings-shell nav button {
    padding: 6px;
    font-size: 13px;
  }
}

.voice-nav {
  margin-top: 16px;
}
.voice-channel > svg,
.hashbox svg {
  width: 18px;
  height: 18px;
  flex: none;
}
.voice-channel > span {
  overflow: hidden;
  text-overflow: ellipsis;
}
.voice-channel small {
  margin-left: auto;
  color: var(--muted);
  font: 12px var(--mono);
  white-space: nowrap;
}
.voice-channel[data-connected],
.voice-channel[data-connected] small {
  color: var(--lime);
}
.empty-voice {
  padding: 0 11px;
  color: var(--muted);
  font-size: 13px;
}
.voice-occupancy {
  color: var(--muted);
  font-size: 14px;
}
.voice-actions {
  flex-wrap: wrap;
}
.voice-actions .audio-note {
  width: 100%;
  margin: 0;
}
.navgroup .icon[hidden],
.layout-form label[hidden] {
  display: none;
}

.voice-channel[aria-current="page"] {
  background: #303c2a;
  color: var(--lime);
}

.voice-roster button,
#call-bar,
#call-info {
  display: flex;
  align-items: center;
}
.voice-roster {
  list-style: none;
  margin: 2px 0 7px 20px;
  padding: 0 0 0 8px;
  border-left: 1px solid var(--line);
}
.voice-roster button {
  width: 100%;
  gap: 8px;
  padding: 4px;
  border-radius: 5px;
}
.voice-roster button:hover {
  background: var(--side);
}
.voice-roster .avatar {
  width: 22px;
  height: 22px;
}
.voice-roster .avatar svg {
  max-width: 75%;
  max-height: 75%;
}
.voice-roster span:not(.avatar),
#call-room {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.voice-roster small {
  color: var(--muted);
}
#call-bar {
  gap: 6px;
  padding: 5px 16px;
  border-bottom: 1px solid var(--line);
  background: var(--side);
  flex: none;
}
#call-bar[hidden] {
  display: none;
}
#call-info {
  min-width: 0;
  margin-right: auto;
  gap: 10px;
  text-align: left;
  color: var(--lime);
}
#call-info span {
  min-width: 0;
}
#call-info strong,
#call-room {
  display: block;
}
#call-info strong {
  font-size: 13px;
}
#call-room {
  color: var(--muted);
  font-size: 12px;
}
#call-bar .icon {
  width: 40px;
  height: 40px;
}
#call-leave {
  color: #f49d92;
}

#community-choice { margin: 12px 0 0; color: var(--muted); font-size: 12px; }
#community-picker { display: block; margin-top: 4px; width: 100%; }
