:root {
  color-scheme: dark;
  --black: #030604;
  --panel: #08130c;
  --line: #306746;
  --green: #79ff9c;
  --text: #c1ffd0;
  --muted: #a5bcaa;
  font-family: "Courier New", monospace;
  font-size: 16px;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--black); color: var(--text); line-height: 1.5; }
header { border-bottom: 1px solid var(--line); background: var(--panel); }
header nav, main { max-width: 82rem; margin: auto; padding-inline: clamp(.8rem, 3vw, 2.25rem); }
header nav { display: flex; align-items: baseline; flex-wrap: wrap; gap: .45rem 1.25rem; padding-block: .75rem; }
a { color: var(--green); }
.brand { font-weight: bold; text-decoration: none; margin-right: auto; }
h1 { color: var(--green); font-size: clamp(1.85rem, 5vw, 3.1rem); letter-spacing: -.06em; margin: 1.35rem 0 .25rem; line-height: 1.15; }
h1 span { padding-left: .08em; }
h2 { font-size: 1rem; margin: 0; }
.status { min-height: 1.5em; margin: .5rem 0 1rem; color: var(--muted); }
.status[data-error] { color: #ffbd9a; }
.window { border: 1px solid var(--line); background: var(--panel); box-shadow: 3px 3px 0 #183525; }
#welcome { max-width: 32rem; }
.bar { padding: .65rem .85rem; border-bottom: 1px solid var(--line); color: var(--green); background: #102518; }
.contents { padding: 1rem; }
.session { display: flex; align-items: center; flex-wrap: wrap; gap: .45rem 1rem; }
.session strong { margin-right: auto; }
.panes { display: grid; grid-template-columns: 12rem minmax(0, 1fr) 12rem; }
#channels { padding: .65rem; display: grid; align-content: start; gap: .4rem; }
#channels button { text-align: left; }
#channels button[aria-current] { background: var(--green); color: var(--black); font-weight: bold; }
.transcript { border-inline: 1px solid var(--line); min-width: 0; background: var(--black); }
.topic { margin: 0; padding: .6rem .85rem; color: var(--muted); border-bottom: 1px solid var(--line); }
#log { height: clamp(12rem, 44vh, 32rem); overflow: auto; padding: .8rem .85rem; overflow-wrap: anywhere; }
.entry { margin-bottom: .55rem; white-space: pre-wrap; }
.entry time { color: var(--muted); margin-right: .6rem; }
.entry strong { color: var(--green); }
.entry button { min-height: 38px; margin: .2rem 0 .2rem .6rem; padding: .15rem .4rem; font-size: .85em; }
#composer { border-top: 1px solid var(--line); padding: .65rem .85rem; }
.input-row { display: flex; gap: .55rem; }
.input-row input { flex: 1; min-width: 0; }
label { display: block; }
#auth label:not(:first-child) { margin-top: .75rem; }
#auth input:not([type=checkbox]) { width: 100%; }
button, input, select { font: inherit; color: inherit; border: 1px solid #4e8a61; background: var(--black); border-radius: 0; padding: .45rem .65rem; }
button, select { cursor: pointer; min-height: 44px; }
input[type=checkbox] { accent-color: var(--green); width: 1.2rem; height: 1.2rem; vertical-align: middle; }
button:hover { background: #173925; }
button:disabled { opacity: .6; cursor: wait; }
.primary { background: var(--green); color: var(--black); font-weight: bold; }
.primary:hover { background: #a8ffbb; }
:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
#online { list-style: none; padding: 0 .85rem; max-height: 28rem; overflow: auto; overflow-wrap: anywhere; }
#no-users { padding-inline: .85rem; }
.muted { color: var(--muted); }
.actions { display: flex; gap: .6rem; flex-wrap: wrap; margin-top: 1rem; }
details { padding: 1rem 0 2rem; max-width: 62rem; }
summary { cursor: pointer; color: var(--green); min-height: 44px; width: fit-content; }
dt { color: var(--green); font-weight: bold; }
dd { margin: 0 0 .6rem; }
dialog { color: var(--text); background: var(--panel); border: 1px solid var(--green); max-width: min(30rem, 90vw); }
dialog::backdrop { background: #000b; }
@media (max-width: 58rem) {
  .panes { grid-template-columns: minmax(0, 1fr) 10rem; }
  #channels { grid-column: 1 / -1; display: flex; flex-wrap: wrap; }
  .transcript { border-left: 0; }
}
@media (max-width: 39rem) {
  .panes { display: block; }
  .transcript { border: 0; }
  aside { border-top: 1px solid var(--line); }
  #online { display: flex; flex-wrap: wrap; gap: .5rem 1rem; max-height: 6rem; }
}
