@charset "UTF-8";
:root {
  --bg:#f5f7f8;
  --surface:#fff;
  --ink:#203438;
  --muted:#6d7e80;
  --line:#e5eceb;
  --accent:#087f72;
  --accent-dark:#056459;
  --mint:#e3f4ee;
  --danger:#b94040;
  --radius:16px;
  font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  color:var(--ink);
  background:var(--bg);
  font-synthesis:none
}
* {
  box-sizing:border-box
}
body {
  margin:0
}
a {
  color:var(--accent);
  text-decoration:none
}
a:hover {
  text-decoration:underline
}
button,input,select,textarea {
  font:inherit
}
button,.button {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  min-height:44px;
  padding:11px 18px;
  border:1px solid transparent;
  border-radius:10px;
  background:var(--accent);
  color:white;
  font-weight:650;
  cursor:pointer;
  text-align:center;
  text-decoration:none
}
button:hover,.button:hover {
  background:var(--accent-dark);
  text-decoration:none
}
button:disabled {
  opacity:.5;
  cursor:not-allowed
}
.secondary {
  background:var(--surface);
  color:var(--ink);
  border-color:var(--line)
}
.secondary:hover {
  background:var(--mint)
}
.quiet {
  background:transparent;
  color:var(--muted);
  padding:8px 10px
}
.quiet:hover {
  background:var(--mint);
  color:var(--accent)
}
.danger {
  background:var(--danger)
}
input,textarea,select {
  width:100%;
  border:1px solid #cddbd8;
  border-radius:9px;
  padding:12px;
  background:#fff;
  color:var(--ink);
  min-height:46px
}
textarea {
  resize:vertical;
  min-height:92px;
  line-height:1.5
}
input:focus,textarea:focus,select:focus {
  outline:2px solid #76baa8;
  outline-offset:2px
}
label {
  display:grid;
  gap:7px;
  font-size:.9rem;
  font-weight:550;
  margin:14px 0
}
form>button {
  margin-top:8px
}
form {
  margin:0
}
.check {
  display:flex;
  align-items:flex-start;
  gap:10px;
  font-weight:400
}
.check input {
  width:18px;
  min-height:18px;
  margin-top:2px;
  accent-color:var(--accent)
}
h1,h2,h3,p {
  margin-top:0
}
h1 {
  font-size:clamp(1.7rem,3vw,2.45rem);
  line-height:1.15;
  letter-spacing:-.045em
}
h2 {
  font-size:1.22rem;
  letter-spacing:-.025em
}
h3 {
  font-size:1rem
}
p {
  line-height:1.65
}
small,.muted {
  color:var(--muted)
}
.topbar {
  min-height:80px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:22px;
  background:#fff;
  border-bottom:1px solid var(--line);
  padding:16px 32px
}
.brand {
  display:flex;
  gap:12px;
  align-items:center;
  color:var(--ink);
  font-size:1.45rem;
  font-weight:800;
  white-space:nowrap
}
.brand small {
  border-left:1px solid var(--line);
  padding-left:18px;
  margin-left:5px;
  font-size:.8rem;
  font-weight:450
}
.brand-icon {
  display:flex;
  align-items:center;
  justify-content:center;
  width:39px;
  height:39px;
  border-radius:13px 13px 13px 3px;
  background:var(--accent);
  color:#fff;
  font-size:1.4rem
}
.topbar nav {
  display:flex;
  gap:16px;
  align-items:center;
  flex-wrap:wrap;
  font-size:.86rem
}
.topbar nav>a {
  color:var(--muted);
  font-weight:550
}
.topbar nav form {
  display:inline
}
.topbar nav button {
  font-size:.86rem
}
.page {
  max-width:1450px;
  margin:auto;
  padding:28px 32px
}
.page-heading {
  padding:14px 0
}
.eyebrow {
  display:block;
  font-size:.68rem;
  font-weight:750;
  letter-spacing:.13em;
  color:var(--accent);
  margin-bottom:14px
}
.panel,.auth-card {
  background:var(--surface);
  border:1px solid var(--line);
  border-radius:var(--radius);
  padding:26px;
  margin-bottom:22px
}
.auth-card {
  max-width:460px;
  margin:55px auto;
  box-shadow:0 12px 60px #20343808;
  padding:36px
}
.auth-card.wide {
  max-width:790px
}
.auth-card>p {
  color:var(--muted)
}
.auth-card form>button {
  width:100%;
  margin-top:16px
}
.form-grid {
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:0 20px
}
.form-grid>button,.form-grid>p {
  grid-column:1/-1
}
.notice {
  background:var(--mint);
  border-left:3px solid var(--accent);
  padding:14px 18px;
  border-radius:8px
}
.checks {
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:8px;
  padding-left:20px;
  font-size:.85rem
}
.cards {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:22px
}
.cards>.panel {
  margin-bottom:0
}
.cards {
  margin-bottom:22px
}
.row {
  display:flex;
  gap:16px;
  align-items:center;
  flex-wrap:wrap;
  border-bottom:1px solid var(--line);
  padding:12px 0
}
.row>label {
  flex:1;
  min-width:160px
}
.row>p {
  flex:1;
  margin:0
}
.row>button {
  margin:0
}
.actions {
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  margin-top:12px
}
.tabs {
  display:flex;
  gap:8px;
  overflow:auto;
  margin-bottom:25px;
  padding-bottom:5px
}
.tabs a {
  white-space:nowrap;
  padding:12px 16px;
  border-radius:10px;
  color:var(--muted);
  font-weight:600;
  font-size:.88rem
}
.tabs a.active {
  background:var(--accent);
  color:#fff
}
.stats {
  display:grid;
  grid-template-columns:repeat(4,1fr);
  gap:18px
}
.stats .panel strong {
  display:block;
  font-size:2rem;
  margin-top:12px
}
.table-wrap {
  overflow:auto
}
table {
  width:100%;
  border-collapse:collapse;
  font-size:.86rem;
  text-align:left
}
td,th {
  padding:13px 10px;
  border-bottom:1px solid var(--line);
  vertical-align:top
}
th {
  color:var(--muted);
  font-weight:550
}
td {
  overflow-wrap:anywhere
}
summary {
  cursor:pointer;
  font-weight:650;
  min-height:44px;
  padding:12px 0
}
details details {
  border-bottom:1px solid var(--line)
}
dl {
  display:grid;
  grid-template-columns:auto 1fr;
  gap:10px 18px;
  font-size:.9rem
}
dt {
  color:var(--muted)
}
dd {
  margin:0;
  overflow-wrap:anywhere
}
.price {
  font-size:2rem;
  font-weight:700
}
.price small {
  font-size:.85rem;
  font-weight:400
}
.profile {
  max-width:700px;
  margin:auto
}
.pre-wrap,pre {
  white-space:pre-wrap;
  overflow-wrap:anywhere
}
dialog {
  border:1px solid var(--line);
  border-radius:18px;
  padding:28px;
  max-width:520px;
  width:calc(100% - 32px);
  max-height:85dvh;
  color:var(--ink)
}
dialog::backdrop {
  background:#18332b88;
  backdrop-filter:blur(3px)
}
dialog a.button {
  color:#fff
}
.chat-layout {
  display:grid;
  grid-template-columns:260px minmax(0,1fr);
  height:calc(100dvh - 136px);
  min-height:420px;
  background:#fff;
  border:1px solid var(--line);
  border-radius:18px;
  overflow:hidden;
  position:relative
}
.sidebar {
  background:#f8faf9;
  border-right:1px solid var(--line);
  padding:25px 18px;
  display:flex;
  flex-direction:column;
  min-height:0
}
.sidebar-heading {
  padding:0 6px 8px
}
.sidebar-heading h2 {
  font-size:1.18rem
}
.sidebar-heading .eyebrow {
  font-size:.56rem;
  letter-spacing:.12em
}
.full {
  width:100%
}
#room-list {
  overflow:auto;
  flex:1;
  margin-top:15px
}
.list-heading {
  font-size:.65rem;
  letter-spacing:.13em;
  color:#8b9997;
  font-weight:650;
  margin:24px 10px 10px
}
.room-link {
  width:100%;
  justify-content:flex-start;
  background:transparent;
  color:#62736f;
  border:0;
  text-align:left;
  padding:12px;
  display:flex;
  flex-wrap:wrap;
  font-weight:500;
  font-size:.9rem
}
.room-link:hover,.room-link.selected {
  background:#e4f1eb;
  color:#177c65
}
.room-link.selected {
  font-weight:700
}
.room-link small {
  font-size:.64rem;
  width:100%;
  padding-left:14px
}
.sidebar-footer {
  display:flex;
  align-items:center;
  gap:10px;
  border-top:1px solid var(--line);
  padding-top:18px;
  margin-top:12px
}
.sidebar-footer strong {
  font-size:.85rem
}
.sidebar-footer small {
  display:block;
  font-size:.7rem;
  margin-top:4px
}
.avatar {
  width:36px;
  height:36px;
  min-width:36px;
  display:flex;
  align-items:center;
  justify-content:center;
  border-radius:12px;
  background:#ebede4;
  color:#6c7555;
  font-weight:650;
  font-size:.85rem
}
.chat-main {
  display:flex;
  flex-direction:column;
  min-width:0;
  min-height:0
}
.chat-header {
  display:flex;
  align-items:center;
  gap:14px;
  border-bottom:1px solid var(--line);
  padding:22px 28px;
  min-height:91px
}
.chat-header>div {
  flex:1;
  min-width:0
}
.chat-header h1 {
  font-size:1.18rem;
  letter-spacing:-.015em;
  margin:0 0 5px;
  overflow-wrap:anywhere
}
.chat-header p {
  font-size:.75rem;
  color:var(--muted);
  margin:0
}
.chat-header>button {
  font-size:.75rem
}
.chat-status {
  font-size:.84rem;
  color:#8d5528;
  background:#fffbef
}
.chat-status:not(:empty) {
  padding:12px 24px
}
.messages {
  flex:1;
  overflow:auto;
  padding:26px 28px;
  scrollbar-width:thin
}
.message {
  display:flex;
  align-items:flex-start;
  gap:13px;
  margin-bottom:23px
}
.message-content {
  min-width:0;
  flex:1
}
.message-meta {
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:10px;
  font-size:.82rem;
  margin:2px 0 7px
}
.message-meta a {
  color:var(--ink);
  font-weight:650
}
.message-meta time {
  color:#96a29e;
  font-size:.65rem
}
.message-body {
  font-size:.88rem;
  line-height:1.6;
  margin:0;
  white-space:pre-wrap;
  overflow-wrap:anywhere
}
.own>.avatar {
  background:#dcefe9;
  color:#167e66
}
.message-actions {
  display:flex;
  gap:6px;
  flex-wrap:wrap;
  margin-top:4px
}
.message-actions button {
  font-size:.67rem;
  min-height:30px;
  padding:5px 0;
  margin-right:12px
}
.message-actions button:hover {
  text-decoration:underline;
  background:transparent
}
.attachment {
  font-size:.85rem;
  display:inline-flex;
  border:1px solid var(--line);
  padding:10px;
  border-radius:8px;
  margin-top:8px
}
.mention {
  color:var(--accent);
  background:var(--mint);
  border-radius:3px
}
.custom-emoji {
  max-width:28px;
  max-height:28px;
  vertical-align:middle
}
.empty-state {
  text-align:center;
  margin:auto;
  padding:50px 25px;
  color:var(--muted)
}
.empty-state h2 {
  color:var(--ink);
  font-size:1.45rem
}
.greeting {
  display:inline-flex;
  background:var(--mint);
  border-radius:22px 22px 22px 4px;
  padding:20px 25px;
  font-size:2rem;
  color:var(--accent);
  font-weight:750;
  transform:rotate(-5deg);
  margin-bottom:32px
}
.empty-state p {
  font-size:.88rem
}
.soft-pill {
  display:inline-block;
  font-size:.72rem;
  padding:10px 15px;
  background:#f6f8f6;
  border-radius:20px;
  margin-top:18px
}
.composer {
  border:1px solid #dce5e1;
  border-radius:12px;
  margin:0 25px 24px;
  padding:8px 12px;
  background:#fff;
  box-shadow:0 3px 9px #142e2205
}
.composer textarea {
  border:0;
  min-height:68px;
  font-size:.88rem;
  resize:none;
  padding:10px
}
.composer textarea:focus {
  outline:none
}
.composer-footer {
  display:flex;
  align-items:center;
  gap:8px;
  border-top:1px solid #f0f3f1;
  padding-top:8px
}
.composer-footer>div {
  display:flex;
  flex:1
}
.composer-footer button {
  font-size:.76rem;
  min-height:36px;
  padding:8px 12px
}
.composer-footer small {
  font-size:.62rem
}
.composer-footer>button {
  margin:0
}
#reply-context {
  background:var(--mint);
  padding:6px 10px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  font-size:.75rem
}
#emoji-picker {
  max-height:160px;
  overflow:auto
}
#emoji-picker button {
  font-size:.8rem
}
.context-panel {
  position:absolute;
  right:0;
  top:0;
  bottom:0;
  width:370px;
  max-width:100%;
  background:#fff;
  border-left:1px solid var(--line);
  box-shadow:-12px 0 32px #20343809;
  padding:20px;
  overflow:auto;
  z-index:4
}
.context-panel>h2 {
  margin-top:18px
}
.context-panel .message {
  gap:9px
}
.context-panel .message .avatar {
  display:none
}
.notification {
  border-bottom:1px solid var(--line);
  padding:15px 0
}
.notification p {
  font-size:.87rem;
  margin-bottom:8px
}
.notification button,.notification a {
  font-size:.75rem
}
.mobile-only {
  display:none
}
.sr-only {
  position:absolute;
  width:1px;
  height:1px;
  padding:0;
  margin:-1px;
  overflow:hidden;
  clip:rect(0,0,0,0);
  white-space:nowrap;
  border:0
}
[hidden] {
  display:none!important
}
@media(min-width:1250px) {
  .chat-layout:has(.context-panel:not([hidden])) {
    grid-template-columns:250px minmax(0,1fr) 340px
  }
  .context-panel {
    width:340px
  }
  .chat-layout:has(.context-panel:not([hidden])) .chat-main {
    grid-column:2
  }
  .composer-footer small {
    display:none
  }
}
@media(max-width:1000px) {
  .brand small {
    display:none
  }
  .topbar {
    padding:12px 20px
  }
  .page {
    padding:20px
  }
  .chat-layout {
    height:calc(100dvh - 122px);
    grid-template-columns:220px minmax(0,1fr)
  }
  .composer-footer small {
    display:none
  }
  .stats {
    grid-template-columns:repeat(2,1fr)
  }
  .topbar nav {
    gap:10px
  }
}
@media(max-width:700px) {
  .topbar {
    min-height:108px;
    display:block;
    padding:12px 16px
  }
  .brand {
    font-size:1.2rem
  }
  .brand-icon {
    width:31px;
    height:31px;
    font-size:1.1rem;
    border-radius:10px 10px 10px 3px
  }
  .topbar nav {
    margin-top:10px;
    gap:15px;
    flex-wrap:nowrap;
    overflow:auto;
    font-size:.76rem
  }
  .topbar nav>a {
    white-space:nowrap
  }
  .topbar nav button {
    font-size:.76rem;
    min-height:30px;
    padding:3px;
    white-space:nowrap
  }
  .page {
    padding:16px
  }
  .chat-layout {
    height:calc(100dvh - 110px);
    min-height:350px;
    display:flex;
    border-radius:0;
    border:0
  }
  .page:has(.chat-layout) {
    padding:0
  }
  .chat-main {
    width:100%
  }
  .sidebar {
    display:none;
    position:absolute;
    left:0;
    top:0;
    bottom:0;
    width:min(84%,300px);
    z-index:5;
    box-shadow:14px 0 40px #18362c25
  }
  .sidebar.drawer-open {
    display:flex
  }
  .mobile-only {
    display:inline-flex
  }
  .chat-header {
    padding:15px 12px;
    gap:7px;
    min-height:76px
  }
  .chat-header h1 {
    font-size:1rem
  }
  .chat-header p {
    font-size:.67rem
  }
  .chat-header>button {
    padding:9px;
    font-size:.7rem
  }
  .messages {
    padding:22px 16px
  }
  .message {
    gap:10px
  }
  .composer {
    margin:0 12px 12px;
    padding:5px 8px
  }
  .composer-footer {
    gap:3px
  }
  .composer-footer button {
    padding:8px;
    font-size:.74rem
  }
  .context-panel {
    top:76px;
    width:100%;
    bottom:170px;
    padding:16px;
    border-top:1px solid var(--line)
  }
  .cards,.form-grid {
    grid-template-columns:1fr
  }
  .panel {
    padding:20px
  }
  .auth-card {
    margin:18px auto;
    padding:25px
  }
  .checks {
    grid-template-columns:1fr
  }
  .stats {
    gap:10px
  }
  .stats .panel {
    padding:16px
  }
  .stats .panel strong {
    font-size:1.65rem
  }
  .row {
    gap:8px
  }
  .row>label {
    min-width:100%
  }
  .empty-state {
    padding:35px 20px
  }
  .topbar:not(:has(nav)) {
    min-height:68px
  }
  .topbar:not(:has(nav))+.page {
    padding-top:0
  }
  .table-wrap {
    max-width:100%
  }
  dialog {
    padding:22px
  }
}
@media(prefers-reduced-motion:reduce) {
  * {
    scroll-behavior:auto!important
  }
}
body:has(.chat-layout) {
  height:100dvh;
  display:flex;
  flex-direction:column;
  overflow:hidden
}
body:has(.chat-layout)>.topbar {
  flex-shrink:0
}
.page:has(.chat-layout) {
  flex:1;
  min-height:0;
  width:100%
}
.chat-layout {
  height:100%;
  min-height:0
}
@media(max-width:700px) {
  .topbar nav {
    scrollbar-width:none
  }
  .topbar nav::-webkit-scrollbar {
    display:none
  }
  .topbar nav>a {
    display:inline-flex;
    align-items:center;
    min-height:36px
  }
  .sidebar>.mobile-only {
    align-self:flex-end
  }
}
@media(max-width:700px) {
  .message-actions button,.composer-footer button,.topbar nav>a,.topbar nav button {
    min-height:44px
  }
  .context-panel {
    top:var(--chat-header-height,76px);
    bottom:var(--composer-bottom,180px)
  }
}

/* Kurze Befehlsübersicht in allen Chatbereichen. */
.bot-help {
  flex:0 0 auto;
  margin:0;
  padding:0 24px;
  border-bottom:1px solid var(--line);
  background:#f5faf8;
  max-height:28dvh;
  overflow:auto;
}
.bot-help summary {font-size:.82rem;color:var(--accent);min-height:44px}
.bot-help-content {padding:0 0 8px}
.bot-help-content p {font-size:.82rem;margin-bottom:8px}
.bot-help code {font-size:.85rem;overflow-wrap:anywhere}
@media(max-width:700px) {.bot-help {padding:0 16px}.bot-help summary {font-size:.78rem}}
