:root {
  color-scheme: dark;
  --bg: #313338;
  --side: #2b2d31;
  --deep: #1e1f22;
  --line: #3f4147;
  --text: #f2f3f5;
  --muted: #b5bac1;
  --blurple: #5865f2;
  --green: #23a559;
  --danger: #f23f43;
  --card: #232428;
  font-family: "Segoe UI", "Helvetica Neue", sans-serif;
}

* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--text); height: 100vh; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
.hidden { display: none !important; }
.muted { color: var(--muted); font-size: 13px; }
.error { color: var(--danger); font-size: 13px; margin: 0; }

.auth {
  min-height: 100vh;
  display: grid;
  place-items: center;
  background: var(--deep);
}
.auth-card {
  width: min(440px, calc(100% - 32px));
  background: var(--card);
  padding: 32px;
  border-radius: 8px;
  display: grid;
  gap: 12px;
}
.brand { color: var(--blurple); font-weight: 700; letter-spacing: 0.04em; }
.auth-card h1 { margin: 0; text-align: center; }
.auth-card p { margin: 0; text-align: center; }
.auth-card label, dialog label { display: grid; gap: 6px; font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; }
input, textarea, select {
  background: var(--deep);
  border: 1px solid var(--deep);
  border-radius: 4px;
  padding: 10px;
  text-transform: none;
  font-weight: 400;
  font-size: 15px;
}
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--blurple); }
.auth-card button, .primary, .ghost, .new-thread {
  border: 0;
  border-radius: 4px;
  padding: 10px 14px;
}
#auth-submit, .primary { background: var(--blurple); color: white; font-weight: 600; }
.ghost, .link { background: transparent; color: var(--muted); }
.link { padding: 0; text-decoration: underline; }
.banner { background: #2d3a2e; color: #b6f0c2; padding: 10px; border-radius: 4px; }

.app { height: 100vh; display: grid; grid-template-columns: 260px 1fr 280px; }
.app.no-members { grid-template-columns: 260px 1fr; }
.app.no-members .members { display: none; }
.sidebar, .members { background: var(--side); display: flex; flex-direction: column; min-height: 0; }
.sidebar-head, .chat-head { height: 52px; display: flex; align-items: center; justify-content: space-between; padding: 0 16px; border-bottom: 1px solid var(--line); box-shadow: 0 1px 0 rgba(0,0,0,.2); }
.side-scroll, .member-list, .messages { overflow: auto; flex: 1; }
.thread-list { padding: 8px; }
.sidebar-label { color: var(--muted); font-size: 12px; font-weight: 700; padding: 12px 16px 0; text-transform: uppercase; }
#dm-label { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.thread > .label { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.thread.unread { color: var(--text); }
.thread.unread .label { font-weight: 700; }
.unread-count {
  flex: none;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  background: var(--danger);
  color: white;
  font-size: 11px;
  font-weight: 700;
  line-height: 18px;
  text-align: center;
}
.thread {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 2px;
  text-align: left;
  background: transparent;
  border: 0;
  color: var(--muted);
  border-radius: 4px;
  padding: 0 4px 0 0;
  margin-bottom: 2px;
}
.thread-open {
  flex: 1;
  min-width: 0;
  text-align: left;
  background: transparent;
  border: 0;
  color: inherit;
  border-radius: 4px;
  padding: 8px 8px 8px 10px;
}
.thread-open .label { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.thread-tools { display: none; flex: none; align-items: center; }
.thread:hover .thread-tools, .thread.active .thread-tools { display: flex; }
.thread-tools button {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: var(--muted);
}
.thread-tools button:hover { color: var(--text); background: #35373c; }
.thread.active, .thread:hover { background: #404249; color: var(--text); }
.thread.child-open { color: var(--text); }
.thread.child-open .label { font-weight: 600; }
.new-thread { margin: 8px; background: var(--deep); color: var(--text); }
.me { display: flex; align-items: center; gap: 8px; padding: 10px; background: #232428; }
.me-name { flex: 1; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.avatar, .msg-avatar {
  width: 32px; height: 32px; border-radius: 50%;
  display: grid; place-items: center; background: var(--blurple); font-weight: 700; flex: none;
}
.chat { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.chat-title { font-weight: 700; }
.chat-title::before { content: "# "; color: var(--muted); font-weight: 500; }
.chat-title.dm::before, .chat-title.list::before { content: ""; }
.cursor-toggle { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); }
.shot-preview { display: flex; gap: 8px; padding: 0 0 8px; }
.shot-chip { position: relative; }
.shot-chip img, .shot { max-width: 220px; max-height: 160px; border-radius: 6px; display: block; }
.shot { margin-top: 6px; }
.shot-chip button { position: absolute; top: 4px; right: 4px; border: 0; border-radius: 4px; background: rgba(0,0,0,.7); color: white; font-size: 11px; padding: 2px 6px; }
.member-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.head-actions { display: flex; gap: 8px; }
.messages { padding: 16px 16px 8px; }
.msg { display: grid; grid-template-columns: 40px 1fr; gap: 12px; padding: 8px 8px; border-radius: 4px; }
.msg:hover { background: #2e3035; }
.msg-main { min-width: 0; }
.msg-top { display: flex; align-items: center; gap: 8px; }
.msg-name { font-weight: 600; }
.msg time { color: var(--muted); font-size: 12px; }
.msg-delete {
  margin-left: auto;
  flex: none;
  border: 1px solid var(--danger);
  background: transparent;
  color: var(--danger);
  border-radius: 4px;
  padding: 2px 8px;
  font-size: 12px;
  font-weight: 600;
}
.msg-delete:hover { background: var(--danger); color: white; }
.md { margin-top: 4px; line-height: 1.45; word-break: break-word; }
.md p { margin: 0 0 8px; }
.md h1, .md h2, .md h3 { margin: 12px 0 6px; font-size: 15px; }
.md ul, .md ol { margin: 0 0 8px; padding-left: 20px; }
.md li { margin: 2px 0; }
.md code { background: #1e1f22; border-radius: 4px; padding: 1px 4px; font-family: Consolas, monospace; font-size: 13px; }
.md pre { background: #1e1f22; border-radius: 6px; padding: 10px; overflow: auto; margin: 0 0 8px; }
.md pre code { padding: 0; background: transparent; }
.md table { width: 100%; border-collapse: collapse; margin: 0 0 10px; font-size: 13px; }
.md th, .md td { border: 1px solid #3f4147; padding: 6px 8px; text-align: left; vertical-align: top; }
.md th { background: #2b2d31; }
.md a { color: #00a8fc; }
.tag { font-size: 10px; background: var(--blurple); color: white; border-radius: 4px; padding: 1px 4px; margin-right: 6px; vertical-align: 1px; }
.tag.team { background: #3f4147; }
.msg.agent .msg-avatar, .msg.typing .msg-avatar { background: #23a559; }
.msg.system .msg-avatar { background: #f0b232; color: #1e1f22; }
.reply-ref {
  margin-top: 6px;
  padding: 4px 8px;
  border-left: 3px solid var(--blurple);
  background: #2b2d31;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.3;
  border-radius: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.typing { margin-top: 4px; color: var(--muted); font-style: italic; }
.composer { padding: 0 16px 16px; flex: none; }
.composer textarea {
  width: 100%;
  resize: none;
  min-height: 44px;
  max-height: min(280px, 40vh);
  height: 44px;
  overflow-y: hidden;
  line-height: 1.4;
  background: #383a40;
  border-radius: 8px;
}
.composer-actions { display: flex; justify-content: flex-end; align-items: center; gap: 8px; margin-top: 8px; }
#composer-error { margin-right: auto; }
.member-search { margin: 12px 12px 0; width: calc(100% - 24px); }
.member-list { padding: 8px 8px 12px; }
.group-label { color: var(--muted); font-size: 12px; font-weight: 700; margin: 10px 8px 6px; text-transform: uppercase; }
.member { display: grid; grid-template-columns: 32px 1fr; gap: 8px; align-items: center; margin: 0; padding: 6px 8px; border-radius: 4px; }
.member:hover { background: #404249; }
.people-list { display: grid; max-height: 420px; overflow: auto; }
.server-logs {
  margin: 12px 0 0;
  max-height: 60vh;
  overflow: auto;
  background: #111214;
  color: #d7dbe0;
  border-radius: 6px;
  padding: 12px;
  font-family: Consolas, monospace;
  font-size: 12px;
  line-height: 1.45;
  white-space: pre-wrap;
  word-break: break-word;
}
dialog.members-dialog { width: min(760px, calc(100% - 24px)); padding: 22px 22px 16px; }
dialog.logs-dialog { width: min(920px, calc(100% - 24px)); padding: 22px; }
.members-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 16px 0 10px; }
.members-toolbar input { width: min(280px, 100%); }
.members-table-wrap { max-height: 460px; overflow: auto; }
.members-table { width: 100%; border-collapse: collapse; }
.members-table th { text-align: left; color: var(--muted); font-size: 12px; font-weight: 700; padding: 8px; border-bottom: 1px solid var(--line); }
.members-table td { padding: 8px; border-bottom: 1px solid rgba(255,255,255,.04); vertical-align: middle; }
.members-table td:nth-last-child(2) { width: 160px; }
.members-table td:last-child { width: 48px; text-align: right; }
.role-select { width: 100%; padding: 6px 8px; font-size: 13px; }
.role-fixed { display: inline-block; padding: 6px 2px; font-size: 13px; font-weight: 600; }
.members-table tr:hover td { background: #2b2d31; }
.member-person { display: flex; align-items: center; gap: 10px; }
.member-person strong, .member-person span { display: block; }
.member-more { width: 32px; height: 32px; border: 0; border-radius: 4px; background: transparent; color: var(--muted); font-size: 20px; line-height: 1; }
.member-more:hover, .member-more.open { background: #404249; color: var(--text); }
.member-menu { position: fixed; z-index: 5; min-width: 180px; padding: 6px; border-radius: 8px; background: #111214; box-shadow: 0 8px 24px rgba(0,0,0,.45); }
.member-menu button { display: block; width: 100%; text-align: left; background: transparent; border: 0; border-radius: 4px; padding: 8px 10px; }
.member-menu button:hover { background: #404249; }
.member-menu button.danger, .member-menu button.danger:hover { color: var(--danger); }
.member strong { display: block; font-size: 14px; }
.member select, .member .tiny { width: 100%; margin-top: 4px; padding: 4px; font-size: 12px; }
.tiny { background: transparent; color: var(--danger); border: 0; padding: 0; text-align: left; }
.member-actions [data-dm-user] { color: var(--text); }

dialog {
  border: 0;
  border-radius: 8px;
  background: var(--card);
  color: var(--text);
  width: min(480px, calc(100% - 24px));
  padding: 0;
}
dialog.channel-settings {
  width: min(880px, calc(100% - 24px));
  max-height: calc(100% - 48px);
}
.channel-layout { display: grid; grid-template-columns: 200px 1fr; min-height: 520px; }
.channel-nav { background: var(--deep); padding: 16px 8px; display: flex; flex-direction: column; gap: 2px; }
.channel-nav-title { color: var(--muted); font-size: 12px; font-weight: 700; padding: 4px 10px 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.channel-nav button { text-align: left; background: transparent; border: 0; color: var(--muted); border-radius: 4px; padding: 8px 10px; }
.channel-nav button.active, .channel-nav button:hover { background: #404249; color: var(--text); }
.channel-nav .danger { margin-top: auto; color: var(--danger); background: transparent; }
.channel-nav .danger:hover { background: rgba(242, 63, 67, 0.15); color: var(--danger); }
.channel-main { position: relative; padding: 28px 48px 24px 24px; overflow: auto; }
.channel-main h2 { margin: 0 0 12px; }
.channel-main form { padding: 0; }
.channel-close { position: absolute; top: 8px; right: 8px; font-size: 22px; line-height: 1; padding: 4px 8px; }
.invite-create { display: grid; gap: 10px; margin: 12px 0; }
.settings-list { display: grid; gap: 8px; margin-top: 16px; }
.settings-row, .invite-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; background: var(--deep); border-radius: 6px; padding: 10px; }
.invite-row strong { display: block; }
.invite-actions { display: flex; gap: 6px; flex: none; }
dialog::backdrop { background: rgba(0,0,0,.7); }
dialog form { display: grid; gap: 12px; padding: 20px; }
dialog h2 { margin: 0; }
details { background: var(--deep); border-radius: 6px; padding: 10px; }
details summary { cursor: pointer; color: var(--muted); }
details label { margin-top: 10px; }
.row { display: flex; justify-content: flex-end; gap: 8px; }
.invite-link { background: var(--deep); padding: 10px; border-radius: 4px; word-break: break-all; text-align: left; }
.existing-users { display: grid; gap: 8px; max-height: 220px; overflow: auto; }
.invite-person { display: flex; align-items: center; justify-content: space-between; gap: 8px; background: var(--deep); border-radius: 4px; padding: 8px; }
.invite-person button { border: 0; border-radius: 4px; background: var(--blurple); color: white; padding: 6px 10px; }

.sub-list {
  margin: 0 6px 8px 18px;
  padding-left: 8px;
  border-left: 2px solid #3f4147;
  display: grid;
  gap: 2px;
}
.sub-item {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 8px;
  text-align: left;
  background: transparent;
  border: 0;
  color: var(--muted);
  border-radius: 4px;
  padding: 5px 8px;
  font-size: 13px;
}
.sub-item .label { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sub-item:hover { background: rgba(255, 255, 255, 0.05); color: var(--text); }
.sub-item.active {
  background: rgba(88, 101, 242, 0.18);
  color: white;
  box-shadow: inset 3px 0 0 var(--blurple);
}
.sub-item .open-count {
  flex: none;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  background: #3b2f1e;
  color: #faa61a;
  font-size: 11px;
  font-weight: 700;
  line-height: 18px;
  text-align: center;
}
.create-list {
  margin: 10px 12px 0;
  background: var(--deep);
  border: 0;
  border-radius: 4px;
  padding: 8px 10px;
  text-align: left;
  color: var(--text);
  font-weight: 600;
}
.create-list:hover { background: #404249; }
.task-page { flex: 1; min-height: 0; display: flex; padding: 0; }
.task-board { flex: 1; min-height: 0; display: grid; grid-template-columns: minmax(300px, 420px) minmax(0, 1fr); }
.task-list-pane, .task-detail-pane { min-height: 0; min-width: 0; }
.task-list-pane { display: flex; flex-direction: column; background: var(--side); border-right: 1px solid var(--line); }
.task-toolbar { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.task-filters { display: flex; gap: 4px; flex: 1; min-width: 0; overflow: auto; }
.task-filters button {
  flex: none;
  border: 0;
  background: transparent;
  color: var(--muted);
  border-radius: 999px;
  padding: 5px 10px;
  font-size: 13px;
}
.task-filters button span { margin-left: 4px; font-weight: 700; }
.task-filters button.all { color: #c9cdfb; }
.task-filters button.open { color: #faa61a; }
.task-filters button.resolved { color: #23a559; }
.task-filters button.closed { color: #b5bac1; }
.task-filters button.all:hover, .task-filters button.all.active { background: rgba(88, 101, 242, 0.22); color: #dee0fc; }
.task-filters button.open:hover, .task-filters button.open.active { background: #3b2f1e; color: #faa61a; }
.task-filters button.resolved:hover, .task-filters button.resolved.active { background: #1e3a2f; color: #23a559; }
.task-filters button.closed:hover, .task-filters button.closed.active { background: #3a3c41; color: #d6d8dc; }
.task-filters button.active { box-shadow: inset 0 0 0 1px currentColor; }
#task-add { flex: none; padding: 6px 12px; }
.task-rows { overflow: auto; flex: 1; }
.task-group {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 14px 6px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.task-row {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  text-align: left;
  background: transparent;
  border: 0;
  border-bottom: 1px solid rgba(63, 65, 71, 0.7);
  color: var(--text);
  padding: 11px 14px;
}
.task-row:hover, .task-row.active { background: #35373c; }
.task-row.closed strong { color: var(--muted); text-decoration: line-through; }
.task-dot { width: 9px; height: 9px; border-radius: 50%; flex: none; }
.task-dot.open { background: #faa61a; }
.task-dot.resolved { background: #23a559; }
.task-dot.closed { background: #80848e; }
.task-row-main { flex: 1; min-width: 0; display: grid; gap: 2px; }
.task-row-main strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.task-row-meta { display: flex; align-items: center; gap: 6px; min-width: 0; flex-wrap: wrap; }
.task-row-meta .muted, .task-empty { font-size: 12px; }
.row-tag { flex: none; background: #1e3a2f; color: #b6f0c2; border-radius: 999px; padding: 1px 7px; font-size: 11px; font-weight: 700; }
.task-empty { padding: 24px 14px; }
.task-detail-pane { overflow: auto; background: var(--bg); container-type: inline-size; }
.task-form { max-width: 640px; padding: 28px 36px 48px; display: grid; gap: 12px; }
.task-detail { padding: 0; }
#task-detail { min-height: 0; }
.task-detail-head {
  position: sticky;
  top: 0;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px 20px;
  padding: 16px 20px;
  background: #2b2d31;
  border-bottom: 1px solid var(--line);
}
.task-detail-title { flex: 1; min-width: min(100%, 280px); }
.task-detail-title h2 { margin: 8px 0 4px; font-size: 20px; line-height: 1.35; }
.task-detail-title p { margin: 0; }
.task-detail-body { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; padding: 20px 24px 40px; }
.task-detail-body.has-shots { grid-template-columns: minmax(0, 1fr) minmax(260px, 440px); align-items: start; }
@container (max-width: 680px) {
  .task-detail-body.has-shots { grid-template-columns: 1fr; }
}
.task-copy h3 {
  margin: 16px 0 10px;
  color: var(--muted);
  font-size: 12px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.task-copy h3:first-child { margin-top: 0; }
.task-thumbs { display: flex; flex-wrap: wrap; gap: 10px; }
.task-thumb {
  width: 112px;
  height: 112px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: var(--deep);
  cursor: zoom-in;
}
.task-thumb:hover, .task-thumb:focus-visible { border-color: var(--blurple); outline: none; }
.task-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
dialog.shot-lightbox {
  width: auto;
  max-width: calc(100vw - 32px);
  max-height: calc(100vh - 32px);
  padding: 0;
  background: transparent;
  overflow: visible;
}
dialog.shot-lightbox[open] {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}
dialog.shot-lightbox::backdrop { background: rgba(0, 0, 0, 0.82); }
dialog.shot-lightbox img {
  max-width: min(1000px, calc(100vw - 160px));
  max-height: calc(100vh - 120px);
  object-fit: contain;
  border-radius: 8px;
  background: #111214;
}
.shot-nav, .shot-lightbox-close {
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 50%;
  background: #2b2d31;
  color: white;
  font-size: 24px;
  line-height: 1;
}
.shot-lightbox-close { position: fixed; top: 16px; right: 16px; }
.shot-count { position: fixed; bottom: 16px; left: 0; right: 0; margin: 0; text-align: center; color: white; }
.task-form h2 { margin: 0; font-size: 22px; line-height: 1.35; }
.task-form label { display: grid; gap: 6px; font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; }
.task-form-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
#task-detail { min-height: 0; }
.tag-row { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; max-width: 420px; }
.task-tag-label { color: var(--muted); font-size: 11px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }
.tag-chip { display: inline-flex; align-items: center; gap: 4px; background: #1e3a2f; color: #b6f0c2; border-radius: 999px; padding: 4px 8px; font-size: 13px; }
.tag-chip button { border: 0; background: transparent; color: inherit; padding: 0 2px; font-size: 16px; line-height: 1; }
.tag-choices { display: flex; flex-wrap: wrap; gap: 8px 14px; margin-top: 8px; }
.tag-choice { display: flex; align-items: center; gap: 6px; text-transform: none; font-weight: 500; font-size: 14px; letter-spacing: 0; color: var(--text); }
.task-placeholder { height: 100%; min-height: 280px; display: grid; place-items: center; color: var(--muted); padding: 28px; }
.status-pill { flex: none; font-size: 11px; font-weight: 700; letter-spacing: 0.04em; border-radius: 999px; padding: 3px 8px; text-transform: uppercase; }
.status-pill.open { background: #3b2f1e; color: #faa61a; }
.status-pill.resolved { background: #1e3a2f; color: #23a559; }
.status-pill.closed { background: #3a3c41; color: #b5bac1; }
.task-note-form { display: grid; gap: 8px; margin: 0 24px 28px; padding-top: 16px; border-top: 1px solid var(--line); }
.task-note-form label { display: grid; gap: 6px; font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; }
.task-note { padding: 12px 0; border-top: 1px solid var(--line); }
.task-note-top { display: flex; align-items: center; gap: 8px; margin-bottom: 4px; }
.task-note-top time { color: var(--muted); font-size: 12px; }
.note-delete { margin-left: auto; border: 0; background: transparent; color: var(--danger); font-size: 12px; padding: 2px 6px; }
.task-note .task-thumb { width: 72px; height: 72px; }
.task-tag { display: grid; gap: 4px; min-width: 180px; font-size: 11px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--muted); }
.task-tag select { text-transform: none; font-weight: 500; font-size: 14px; letter-spacing: 0; padding: 8px 10px; }
.task-assignee { align-self: center; background: #3b2f1e; color: #faa61a; border-radius: 999px; padding: 4px 10px; font-size: 12px; font-weight: 700; }
.task-actions { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; justify-content: flex-end; }
.task-actions select.status-select { width: auto; min-width: 128px; padding: 8px 10px; font-size: 14px; font-weight: 600; }
.task-actions select.status-select.open { color: #faa61a; }
.task-actions select.status-select.resolved { color: #23a559; }
.task-actions select.status-select.closed { color: #b5bac1; }
.task-actions button, .task-form-actions .ghost {
  border: 0;
  border-radius: 6px;
  padding: 8px 12px;
  background: var(--deep);
  color: var(--text);
}
.task-actions button:disabled { opacity: 0.55; cursor: default; }
.task-actions button.cursor-send { background: var(--blurple); color: white; font-weight: 600; }
.agent-reply { background: var(--card); border-radius: 8px; padding: 14px; margin-top: 8px; }
.agent-reply .md p:first-child { margin-top: 0; }

@media (max-width: 900px) {
  .app, .app.no-members { grid-template-columns: 72px 1fr; }
  .members { display: none; }
  .sidebar-head strong, .me-name, .thread .label { display: none; }
  .sub-list { display: none; }
  .channel-layout { grid-template-columns: 1fr; }
  .channel-nav { flex-direction: row; flex-wrap: wrap; }
  .channel-nav .danger { margin-top: 0; }
  .task-board { grid-template-columns: 1fr; }
  .task-list-pane { max-height: 42vh; border-right: 0; border-bottom: 1px solid var(--line); }
  .task-form { padding: 20px 16px 32px; }
  .task-detail-body, .task-detail-body.has-shots { grid-template-columns: 1fr; padding: 16px; }
  .task-detail-head { padding: 14px 16px; }
}
