/* ═════════════════════════════════════════════════════════════════════════
   SCHNACK EIGEN (27.09.2026)

   Eigene Oberfläche über app.css und schnack.css: Runden-Leiste oben,
   Profil oben rechts, Gesprächsleiste über dem Chat, Reiter-Einstellungen,
   eigene Profilkarte und Nachrichtenmenü. Klassen, die app.js kennt, bleiben.
   Zum Zurückdrehen reicht es, den <link> auf diese Datei aus index.html zu nehmen.
   ═══════════════════════════════════════════════════════════════════════ */

:root {
  --font: "Outfit", system-ui, sans-serif;
  --display: "Outfit", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  --hot: #ff9f6b;
  --eigen-rail-h: 56px;
}

body { font-family: var(--font); letter-spacing: 0.005em; }

.server__full { display: none; }
.rail-me { display: none; }

/* ── Desktop: Runden oben, darunter Kanäle · Chat · Leute ─────────────────── */

@media (min-width: 980px) {
  .layout {
    grid-template-columns: 268px minmax(0, 1fr) 260px;
    grid-template-rows: var(--eigen-rail-h) auto auto minmax(0, 1fr) auto;
  }
  .layout.is-home { grid-template-columns: 268px minmax(0, 1fr); }

  .rail {
    grid-column: 1 / -1;
    grid-row: 1;
    width: auto;
    height: var(--eigen-rail-h);
    flex-direction: row;
    align-items: stretch;
    gap: 0.75rem;
    padding: 0 0.85rem;
    border-bottom: 1px solid var(--line);
    background: linear-gradient(180deg, #121020, #0c0b14);
  }
  .rail__servers {
    flex: 1;
    min-width: 0;
    flex-direction: row;
    align-items: center;
    gap: 0.25rem;
    padding: 0;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
  }
  .rail__servers::-webkit-scrollbar { display: none; }
  .rail .server {
    flex: none;
    width: auto;
    max-width: 230px;
    height: 38px;
    min-height: 0;
    flex-direction: row;
    gap: 0.5rem;
    padding: 0 0.85rem 0 0.3rem;
    border: 1px solid transparent;
    border-radius: 10px;
    background: transparent;
    box-shadow: none;
  }
  .rail__servers.is-compact .server:not(.server--home):not(.server-add):not(.active) { padding: 0 0.3rem; }
  .rail__servers.is-compact .server:not(.server--home):not(.server-add):not(.active) .server__full { display: none; }
  .rail__servers { padding-right: 24px; mask-image: linear-gradient(90deg, #000 calc(100% - 24px), transparent); -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 24px), transparent); }
  .rail .server__face { width: 28px; height: 28px; border-radius: 8px; flex: none; }
  .rail .server__face img { border-radius: 8px; }
  .rail .server__name { display: none; }
  .rail .server__full {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--muted);
  }
  .rail .server:hover { background: rgba(255, 255, 255, 0.05); border-radius: 10px; }
  .rail .server:hover .server__full { color: var(--text); }
  .rail .server.active {
    background: var(--panel-2);
    border-color: var(--line-2);
    border-radius: 10px;
    box-shadow: none;
  }
  .rail .server.active .server__full { color: var(--text); }
  .rail .server.active::before {
    left: 0.7rem;
    right: 0.7rem;
    top: auto;
    bottom: -10px;
    width: auto;
    height: 3px;
    transform: none;
    border-radius: 3px 3px 0 0;
    background: var(--grad);
    box-shadow: none;
  }
  .rail .server.has-unread:not(.active)::before {
    left: auto;
    right: 6px;
    top: 6px;
    bottom: auto;
    width: 7px;
    height: 7px;
    transform: none;
    border-radius: 50%;
    background: var(--hot);
  }
  .rail .server .badge {
    position: static;
    border: 0;
    height: 18px;
    min-width: 18px;
    margin-left: 0.1rem;
    font-size: 0.7rem;
    background: var(--hot);
    color: #1b0f08;
  }
  .rail .server-add { border: 1px dashed rgba(141, 107, 255, 0.5); padding-right: 0.85rem; }
  .rail .server-add .server__face { background: transparent; color: #c4b0ff; }
  .rail .server-add .server__full { color: #c4b0ff; }

  .rail-me { display: flex; align-items: center; gap: 0.35rem; flex: none; }
  .rail-me__who {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border: 0;
    background: transparent;
    color: var(--text);
    padding: 0.2rem 0.55rem 0.2rem 0.2rem;
    border-radius: 10px;
  }
  .rail-me__who:hover { background: rgba(255, 255, 255, 0.05); }
  .rail-me__who .avatar { width: 32px; height: 32px; border-radius: 10px; }
  .rail-me__who b { display: block; max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 0.9rem; }
  .rail-me__settings { width: 34px; height: 34px; border-radius: 10px; }

  .me-bar { display: none !important; }
  .topbar .who, .topbar #openSettingsTop { display: none !important; }

  .side { grid-column: 1; grid-row: 2 / span 4; }
  .topbar { grid-column: 2; grid-row: 2; }
  .chat { grid-column: 2; grid-row: 4; }
  .composer-wrap { grid-column: 2; grid-row: 5; }
  .members {
    grid-column: 3;
    grid-row: 2 / span 4;
    margin: 0.65rem 0.65rem 0.65rem 0;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: var(--panel);
    overflow: hidden;
  }
  .channels, .layout.voice-on .channels { padding-bottom: 1rem; }
  .thread-pane { top: var(--eigen-rail-h); }

  /* Gesprächsleiste: über dem Chat statt unten links */
  .voice-side {
    grid-column: 2;
    grid-row: 3;
    position: relative;
    left: auto;
    bottom: auto;
    width: auto;
    margin: 0.55rem 0.9rem 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.4rem 0.75rem;
    padding: 0.45rem 0.6rem;
  }
  .voice-side[hidden] { display: none; }
  .voice-side__head { flex: 1 1 12rem; min-width: 0; }
  .voice-side__row { margin: 0; }
}

/* Gesprächsleiste und Status-Wort: Schnack-Farben statt Grün */
.voice-side__name { color: var(--text); }
.voice-side__status { color: var(--muted); }
.voice-side {
  background: linear-gradient(135deg, rgba(141, 107, 255, 0.16), rgba(255, 159, 107, 0.08));
  border: 1px solid rgba(141, 107, 255, 0.35);
}
.presence-word {
  border: 1px solid var(--line-2);
  border-radius: 999px;
  padding: 0.18rem 0.65rem;
  font-size: 0.78rem;
  font-weight: 600;
  background: transparent;
  color: var(--muted);
  white-space: nowrap;
}
.presence-word--online { color: #8ce6bb; border-color: rgba(140, 230, 187, 0.35); }
.presence-word--away { color: #f5c778; border-color: rgba(245, 199, 120, 0.35); }
.presence-word--busy { color: #d7b8ff; border-color: rgba(215, 184, 255, 0.4); }
.presence-word--offline { color: var(--muted); }

.add-menu { position: fixed; z-index: 60; min-width: 220px; }
.member__name[style*="--role"] { color: var(--role); }
.base-role__move { flex: none; display: inline-flex; gap: 2px; }
.base-role__move .icon-btn, .base-role__move button { width: 28px; height: 28px; }
.base-role__bot { flex: none; width: 32px; text-align: center; font-size: 1.1rem; }
.base-role__fixed { padding-left: 0.45rem; color: var(--role); }
.live-tag,
.voice-who--mini b.live {
  display: inline-grid;
  place-items: center;
  padding: 0 0.32rem;
  border-radius: 4px;
  background: #e5373c;
  color: #fff;
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  line-height: 1.45;
  box-shadow: 0 0 8px rgba(229, 55, 60, 0.55);
}
.live-tag { margin-left: 0.3rem; vertical-align: 1px; }
.voice-who--mini b.live { right: -8px; bottom: -5px; font-size: 0.5rem; padding: 0 0.22rem; }
.member-admin__search { width: 100%; margin: 0.4rem 0 0.8rem; }
.member-admin { display: grid; gap: 0.5rem; }
.member-admin__row {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.35rem 0.75rem;
  padding: 0.6rem 0.75rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.025);
}
.member-admin__row > .avatar { width: 40px; height: 40px; grid-row: span 2; align-self: start; }
.member-admin__who { min-width: 0; }
.member-admin__who b { display: inline; }
.member-admin__who small { display: block; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.member-admin__owner {
  margin-left: 0.35rem;
  padding: 0 0.4rem;
  border: 1px solid rgba(242, 193, 78, 0.6);
  border-radius: 999px;
  color: #f2c14e;
  font-size: 0.66rem;
}
.member-admin__base select { min-width: 150px; }
.member-admin__roles, .member-admin__acts { grid-column: 2 / -1; display: flex; flex-wrap: wrap; gap: 0.35rem; }
.member-admin__acts .btn { padding: 0.3rem 0.7rem; font-size: 0.8rem; }
.member-admin__ban { color: #ffb4ae; border-color: rgba(240, 113, 107, 0.45); }
.member-admin__ban:hover { background: #c7362f; color: #fff; }
@media (max-width: 560px) {
  .member-admin__row { grid-template-columns: 36px minmax(0, 1fr); }
  .member-admin__base { grid-column: 2; }
}
.composer-end .plus-menu { left: auto; right: 0; max-width: calc(100vw - 24px); }
.msg--dmhit .msg__actions { display: none !important; }
.msg--dmhit .msg__reacts { pointer-events: none; }
.dm-row { position: relative; }
.dm-row.is-unread { background: rgba(255, 159, 107, 0.08); }
.dm-row.is-unread .dm-row__top b { color: #fff; font-weight: 800; }
.dm-row.is-unread small { color: var(--text, #e9e6f2); }
.dm-row .dot-unread { position: absolute; right: 10px; bottom: 12px; }
.inbox > .friends-panel { margin-top: 1rem; }
.side-logout {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  width: 100%;
  min-height: 38px;
  border: 1px solid rgba(240, 113, 107, 0.55);
  border-radius: 10px;
  background: rgba(240, 113, 107, 0.1);
  color: #ffb4ae;
  font-weight: 600;
}
.side-logout:hover { background: #c7362f; border-color: #c7362f; color: #fff; }
.side-logout .ico { width: 16px; height: 16px; }
.game-detail { margin: 0.4rem 0 0.8rem; }
.game-detail .inline-form { display: flex; gap: 0.45rem; }
.game-detail .inline-form input { flex: 1; min-width: 0; }

/* ── Handy: Runden oben als Reihe, feste Leiste unten ────────────────────── */

.mnav { display: none; }
.me-menu { position: fixed; z-index: 70; min-width: 210px; }
.me-menu .presence { position: static; width: 10px; height: 10px; margin: 0 0.2rem; }

@media (max-width: 979px) {
  :root { --mnav-h: calc(60px + env(safe-area-inset-bottom, 0px)); }
  .topbar #openSettingsTop { display: none; }
  .me-bar { display: none !important; }

  .layout { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr) auto; }
  .rail {
    grid-column: 1;
    grid-row: 1;
    width: auto;
    height: 54px;
    flex-direction: row;
    align-items: center;
    padding: 0 0.5rem;
    border-bottom: 1px solid var(--line);
    background: linear-gradient(180deg, #121020, #0c0b14);
  }
  .rail__servers {
    flex: 1;
    min-width: 0;
    flex-direction: row;
    align-items: center;
    gap: 0.3rem;
    padding: 0 1rem 0 0;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 20px), transparent);
    mask-image: linear-gradient(90deg, #000 calc(100% - 20px), transparent);
  }
  .rail__servers::-webkit-scrollbar { display: none; }
  .rail .server {
    flex: none;
    width: auto;
    height: 40px;
    min-height: 0;
    flex-direction: row;
    gap: 0.45rem;
    padding: 0 0.3rem;
    border: 1px solid transparent;
    border-radius: 11px;
    background: transparent;
    box-shadow: none;
  }
  .rail .server--home { display: none; }
  .rail .server__face { width: 30px; height: 30px; border-radius: 9px; }
  .rail .server__name { display: none; }
  .rail .server.active { padding-right: 0.75rem; background: var(--panel-2); border-color: var(--line-2); box-shadow: none; }
  .rail .server.active .server__full {
    display: block;
    max-width: 42vw;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--text);
  }
  .rail .server.active::before {
    left: 0.6rem;
    right: 0.6rem;
    top: auto;
    bottom: -8px;
    width: auto;
    height: 3px;
    transform: none;
    border-radius: 3px 3px 0 0;
    background: var(--grad);
    box-shadow: none;
  }
  .rail .server.has-unread:not(.active)::before {
    left: auto;
    right: 2px;
    top: 3px;
    bottom: auto;
    width: 8px;
    height: 8px;
    transform: none;
    border-radius: 50%;
    background: var(--hot);
  }
  .rail .server .badge { position: absolute; top: -3px; right: -3px; border: 2px solid #0c0b14; height: 18px; min-width: 18px; font-size: 0.65rem; background: var(--hot); color: #1b0f08; }
  .rail .server-add { border: 1px dashed rgba(141, 107, 255, 0.5); }
  .rail .server-add .server__face { background: transparent; color: #c4b0ff; }

  .side { grid-column: 1; grid-row: 2 / span 2; }
  .channels, .layout.voice-on .channels { padding-bottom: calc(var(--mnav-h) + 1rem); }

  .mnav {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 30;
    display: flex;
    height: var(--mnav-h);
    padding: 0 0.4rem env(safe-area-inset-bottom, 0px);
    background: rgba(12, 11, 20, 0.96);
    border-top: 1px solid var(--line-2);
    backdrop-filter: blur(10px);
  }
  .layout.in-chat .mnav { display: none; }
  .mnav__item {
    position: relative;
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.2rem;
    border: 0;
    background: transparent;
    color: var(--muted);
    font-size: 0.68rem;
    font-weight: 600;
  }
  .mnav__item:disabled { opacity: 0.4; }
  .mnav__item .ico { width: 22px; height: 22px; }
  .mnav__item.is-on { color: var(--text); }
  .mnav__item.is-on .ico { color: #c4b0ff; }
  .mnav__item.is-on::after {
    content: "";
    position: absolute;
    top: 0;
    left: 30%;
    right: 30%;
    height: 3px;
    border-radius: 0 0 3px 3px;
    background: var(--grad);
  }
  .mnav__item .avatar { width: 24px; height: 24px; border-radius: 8px; }
  .mnav__item--me .presence { position: absolute; top: 9px; left: calc(50% + 7px); width: 9px; height: 9px; }
  .mnav__badge {
    position: absolute;
    top: 6px;
    left: calc(50% + 6px);
    min-width: 17px;
    padding: 0 0.3rem;
    border-radius: 999px;
    background: var(--hot);
    color: #1b0f08;
    font-size: 0.62rem;
    line-height: 17px;
    text-align: center;
  }

  /* Im Chat: keine Leisten oben/unten, Gespräch als Leiste unter dem Kanal-Kopf */
  .layout.in-chat { grid-template-rows: auto auto minmax(0, 1fr) auto; }
  .layout.in-chat .topbar { grid-row: 1; }
  .layout.in-chat .voice-side {
    position: relative;
    left: auto;
    right: auto;
    bottom: auto;
    grid-column: 1;
    grid-row: 2;
    width: auto;
    margin: 0.4rem 0.5rem 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem 0.6rem;
  }
  .layout.in-chat .voice-side[hidden] { display: none; }
  .layout.in-chat .chat { grid-row: 3; }
  .layout.in-chat .composer-wrap,
  .layout.in-chat.voice-on .composer-wrap { grid-row: 4; margin-bottom: env(safe-area-inset-bottom, 0px); }
  .layout:not(.in-chat) .voice-side { bottom: calc(var(--mnav-h) + 8px); }
}

/* ── Profilkarte: Bild neben dem Namen, Banner als weicher Hintergrund ───── */

.profile-card #cardBody, .profile-preview { position: relative; overflow: visible; }
.pc-banner {
  position: absolute;
  inset: 0 0 auto 0;
  height: 150px;
  opacity: 0.55;
  -webkit-mask-image: linear-gradient(180deg, #000 0%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 0%, transparent 100%);
  pointer-events: none;
}
.profile-preview .pc-banner { height: 120px; }
.pc-top,
.profile-preview .pc-top {
  position: relative;
  margin-top: 0;
  padding: 1.35rem 1.1rem 0.4rem;
  align-items: center;
  gap: 0.95rem;
}
.pc-avatar .avatar,
#cardBody .pc-avatar .avatar,
.profile-preview .pc-avatar .avatar {
  width: 76px;
  height: 76px;
  border-radius: 22px;
  border: 0;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(255, 255, 255, 0.08);
}
.pc-avatar .presence { display: none; }
.pc-headline { min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 0.2rem; }
.pc-headline h3 { margin: 0; font-size: 1.3rem; line-height: 1.2; overflow-wrap: anywhere; }
.pc-headline .pc-handle { margin: 0; }
.pc-headline .presence-word { margin-top: 0.2rem; }
.pc-body { position: relative; padding: 0.4rem 1.1rem 1.1rem; }
.pc-status {
  margin: 0.2rem 0 0.8rem;
  padding: 0.1rem 0 0.1rem 0.75rem;
  border-left: 3px solid rgba(255, 159, 107, 0.7);
  color: var(--text);
  font-size: 0.9rem;
  line-height: 1.4;
  overflow-wrap: anywhere;
}
.pc-section h4 { text-transform: none; letter-spacing: 0.01em; font-size: 0.8rem; }
.pc-close { background: rgba(0, 0, 0, 0.35); border-radius: 10px; z-index: 2; }

/* ── Bilder: abgerundete Quadrate statt Kreise ───────────────────────────── */

.avatar, img.avatar { border-radius: 30%; }
img.avatar.avatar--bot {
  box-shadow: 0 0 0 2px #f2c14e, 0 0 0 3px rgba(20, 16, 8, 0.9), 0 0 12px rgba(242, 193, 78, 0.45);
  background: linear-gradient(145deg, #3a2a0c, #1b140a);
}
.msg:has(.avatar--bot) .msg__name,
.member:has(.avatar--bot) .member__name,
.member:has(.avatar--bot) b { color: #f2c14e; }

/* ── Nachrichten: Karten mit Platz fürs Bild ──────────────────────────────── */

.msg {
  margin: 0.2rem 0.75rem 0;
  padding: 0.45rem 2.6rem 0.5rem calc(40px + 1.6rem);
  border-radius: 14px;
}
.msg--grouped { margin-top: 0; padding-top: 0.15rem; padding-bottom: 0.3rem; }
.msg--own { padding-left: calc(40px + 1.6rem); padding-right: 2.6rem; border-radius: 14px; }
.msg__meta .avatar { left: 0.8rem; top: 0.5rem; width: 40px; height: 40px; border-radius: 12px; }
.msg:has(> .msg__reply) .msg__meta .avatar { top: 1.85rem; }
.msg__gtime { left: 0.8rem; width: 40px; }
.msg--own .msg__gtime { left: 0.8rem; }
.msg--join { padding: 0.35rem 1rem 0.35rem calc(40px + 1.6rem); margin-top: 0.3rem; }
.msg--join .join-arrow { left: calc(0.8rem + 10px); color: var(--hot); }
@media (max-width: 979px) {
  .msg { margin: 0.2rem 0.4rem 0; padding: 0.4rem 0.8rem 0.45rem calc(36px + 1.3rem); }
  .msg--own { padding-left: calc(36px + 1.3rem); padding-right: 0.8rem; }
  .msg__meta .avatar { left: 0.6rem; width: 36px; height: 36px; }
  .msg__gtime, .msg--own .msg__gtime { left: 0.6rem; width: 36px; }
  .msg--join { padding-left: calc(36px + 1.3rem); }
  .msg--join .join-arrow { left: calc(0.6rem + 8px); }
}

/* ── Nachrichten: ein „…“ statt schwebender Symbolleiste ─────────────────── */

@media (min-width: 980px) {
  .msg__actions { display: none !important; }
  .msg { position: relative; }
  .msg__more {
    display: inline-grid;
    place-items: center;
    top: 0.3rem;
    right: 0.45rem;
    width: 30px;
    height: 26px;
    padding: 0;
    border: 1px solid var(--line-2);
    border-radius: 999px;
    background: var(--panel-2);
    opacity: 0;
    transition: opacity 0.12s;
  }
  .msg__more .ico { width: 16px; height: 16px; }
  .msg:hover .msg__more, .msg:focus-within .msg__more { opacity: 1; }
  .msg__more:hover { color: var(--text); border-color: rgba(141, 107, 255, 0.55); }
  .msg__quick {
    position: absolute;
    top: 0.3rem;
    right: calc(0.45rem + 36px);
    display: inline-flex;
    gap: 2px;
    padding: 2px;
    border: 1px solid var(--line-2);
    border-radius: 999px;
    background: var(--panel-2);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.12s;
    z-index: 2;
  }
  .msg__quick button {
    width: 28px;
    height: 22px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: transparent;
    font-size: 0.95rem;
    line-height: 1;
    cursor: pointer;
  }
  .msg__quick button:hover { background: rgba(255, 159, 107, 0.18); transform: scale(1.12); }
  .msg:hover .msg__quick, .msg:focus-within .msg__quick { opacity: 1; pointer-events: auto; }
}
@media (max-width: 979px) {
  .msg__quick { display: none; }
}
.msg-ctx__reactrow {
  margin-top: 0.3rem;
  padding: 0.45rem 0.35rem 0.15rem;
  border-top: 1px solid var(--line);
}
.msg-ctx__reactlabel { display: block; margin: 0 0 0.3rem 0.2rem; font-size: 0.72rem; color: var(--muted); }
.msg-ctx__reactrow .msg-ctx__reacts { margin: 0; padding: 0; border: 0; gap: 0.2rem; }
.msg-ctx__reactrow .msg-ctx__emoji { border-radius: 999px; }
.msg-ctx__emoji--more .ico { width: 16px; height: 16px; }

/* ── Überschriften in normaler Schreibweise ──────────────────────────────── */

.channels h2, .members h2, .cat, .day, .thread-sep, .friends-sub, .settings-group__title, .invite-card__label {
  text-transform: none;
  letter-spacing: 0.01em;
}
.channels h2, .members h2, .cat { font-size: 0.8rem; font-weight: 650; }
.members h2 { margin: 1rem 0.4rem 0.35rem; }
.cat { display: flex; align-items: center; gap: 0.35rem; width: 100%; text-align: left; }
.cat__name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cat__chev { display: inline-grid; place-items: center; opacity: 0.6; transition: transform 0.15s; }
.cat__chev .ico { width: 12px; height: 12px; }
.cat__chev.is-shut { transform: rotate(-90deg); }
.day { font-size: 0.76rem; }

/* ── Kanäle: aktiv als Fläche, ungelesen als Punkt rechts ────────────────── */

.channel.active { box-shadow: none; background: rgba(141, 107, 255, 0.16); }
.channel.is-unread::before {
  left: auto;
  right: 0.55rem;
  top: 50%;
  width: 7px;
  height: 7px;
  margin-top: -3.5px;
  border-radius: 50%;
  background: var(--hot);
}
.channel.is-unread:has(.badge)::before { display: none; }
.voice-count { background: rgba(141, 107, 255, 0.18); color: #d7c9ff; }

/* ── Sprachkanal: Bilderreihe statt eingerückter Liste ───────────────────── */

.voice-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  margin: 0.15rem 0 0.4rem 0.6rem;
  padding: 0.3rem 0.4rem;
  border-radius: 10px;
  background: rgba(141, 107, 255, 0.07);
}
.voice-who--mini {
  position: relative;
  display: inline-grid;
  margin: 0;
  padding: 0;
  border-radius: 10px;
  cursor: default;
}
.voice-who--mini.is-me { cursor: pointer; }
.voice-who--mini:hover { background: transparent; }
.voice-who--mini .avatar { width: 28px; height: 28px; border-radius: 9px; box-shadow: 0 0 0 2px transparent; }
.voice-who--mini.talking .avatar { box-shadow: 0 0 0 2px var(--hot); }
.voice-who--mini .live,
.voice-stack__flag {
  position: absolute;
  right: -4px;
  bottom: -4px;
  display: grid;
  place-items: center;
  padding: 0 0.2rem;
  border-radius: 999px;
  background: #13121c;
  color: var(--muted);
  font-size: 0.55rem;
  line-height: 1.4;
}
.voice-stack__flag .ico { width: 11px; height: 11px; }

/* ── „Ab hier neu“ statt Trennlinie ──────────────────────────────────────── */

.unread-line {
  display: flex;
  justify-content: center;
  margin: 0.6rem 1rem;
  color: var(--hot);
  font-size: 0.76rem;
}
.unread-line::before, .unread-line::after { display: none; }
.unread-line span, .unread-line {
  font-weight: 650;
}
.unread-line > b {
  padding: 0.15rem 0.7rem;
  border: 1px solid rgba(255, 159, 107, 0.45);
  border-radius: 999px;
  background: rgba(255, 159, 107, 0.08);
  font-weight: 650;
}

/* ── Helfer-Schild, Kürzel, Teilen-Hinweis ───────────────────────────────── */

.bot-tag {
  background: transparent;
  color: #f2c14e;
  border: 1px solid rgba(242, 193, 78, 0.6);
  border-radius: 999px;
  padding: 0 0.45rem;
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  text-transform: none;
}
.server-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.22rem;
  margin-left: 0.4rem;
  padding: 0.04rem 0.42rem 0.04rem 0.34rem;
  border: 1px solid transparent;
  border-radius: 999px;
  background:
    linear-gradient(135deg, rgba(255, 159, 107, 0.16), rgba(141, 107, 255, 0.16)) padding-box,
    linear-gradient(#16141f, #16141f) padding-box,
    linear-gradient(135deg, #ff9f6b, #8d6bff) border-box;
  color: #ffe2cf;
  font-family: var(--mono);
  font-size: 0.64rem;
  font-weight: 700;
  line-height: 1.45;
  letter-spacing: 0.09em;
  vertical-align: 1px;
  box-shadow: 0 0 10px rgba(255, 159, 107, 0.12);
}
.server-tag__emoji { font-size: 0.78rem; line-height: 1; letter-spacing: 0; }
.server-tag__text { letter-spacing: 0.09em; }
.server-tag__text::before, .server-tag__text::after { content: none; }
.cat-empty { margin: 0.1rem 0.6rem 0.5rem; font-size: 0.75rem; }
.emoji-standard-title { margin-top: 0.9rem; }
.emoji-standard { display: flex; flex-wrap: wrap; gap: 0.35rem 0.8rem; font-size: 0.8rem; color: var(--muted); }
.emoji-standard span { display: inline-flex; align-items: center; gap: 0.3rem; }
.emoji-standard .emoji { width: 22px; height: 22px; }
.cat-row { position: relative; }
.cat[draggable="true"] { cursor: grab; }
.cat-edit {
  display: inline-grid;
  place-items: center;
  width: 22px;
  height: 22px;
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  opacity: 0;
  transition: opacity 0.12s;
}
.cat-edit .ico { width: 13px; height: 13px; }
.cat-row:hover .cat-edit, .cat-edit:focus-visible { opacity: 1; }
.cat-edit:hover { color: var(--text); background: rgba(255, 255, 255, 0.07); }
@media (hover: none) { .cat-edit { opacity: 1; } }
.is-dragging { opacity: 0.45; }
.cat-row.drop-before::before,
.cat-row.drop-after::after {
  content: "";
  position: absolute;
  left: 0.4rem;
  right: 0.4rem;
  height: 3px;
  border-radius: 3px;
  background: linear-gradient(90deg, #ff9f6b, #8d6bff);
  pointer-events: none;
}
.cat-row.drop-before::before { top: -2px; }
.cat-row.drop-after::after { bottom: -2px; }
.cat-row.drop-into, .channel.drop-into {
  outline: 2px dashed rgba(255, 159, 107, 0.75);
  outline-offset: -2px;
  border-radius: 10px;
  background: rgba(255, 159, 107, 0.08);
}
.voice-flags .live {
  background: transparent;
  color: var(--hot);
  border: 1px solid rgba(255, 159, 107, 0.55);
  border-radius: 999px;
  font-size: 0.62rem;
  letter-spacing: 0;
}

/* ── Anruf: Schnack-Farben ───────────────────────────────────────────────── */

.call-ring__btn--yes { background: var(--grad); color: #fff; }
.call-ring__btn--yes:hover { background: var(--grad); filter: brightness(1.1); }
.call-ring__btn--no { background: transparent; color: #ffb4ae; border: 1px solid rgba(240, 113, 107, 0.6); }
.call-ring__btn--no:hover { background: rgba(240, 113, 107, 0.15); }

/* ── Runden finden: Liste statt Karten mit Banner ────────────────────────── */

.discover-grid { grid-template-columns: minmax(0, 1fr); gap: 0.5rem; min-height: 120px; }
.discover-card {
  flex-direction: row;
  align-items: center;
  gap: 0.9rem;
  padding: 0.7rem 0.9rem 0.7rem 1.1rem;
  border-radius: 14px;
}
.discover-card:hover { transform: none; box-shadow: none; }
.discover-card__banner {
  position: absolute;
  inset: 0 auto 0 0;
  width: 5px;
  height: auto;
}
.discover-card__icon { position: static; flex: none; width: 48px; height: 48px; border: 0; border-radius: 14px; }
.discover-card__body { padding: 0; min-width: 0; }
.discover-card__body p { -webkit-line-clamp: 2; margin: 0.15rem 0 0.35rem; }
.discover-card .btn { margin: 0; flex: none; }

/* ── Einladung im Chat: eigene Form ──────────────────────────────────────── */

.invite-card {
  border: 1px dashed rgba(255, 159, 107, 0.55);
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(255, 159, 107, 0.08), rgba(141, 107, 255, 0.08));
  box-shadow: none;
}
.invite-card__label { color: var(--hot); font-size: 0.74rem; font-weight: 650; }

.member__activity {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  margin-top: 0.15rem;
  padding: 0.05rem 0.5rem;
  border-radius: 999px;
  background: rgba(255, 159, 107, 0.1);
  color: #ffc9a8;
  font-size: 0.72rem;
}
.member__activity b { font-weight: 600; }

/* ── Rollenfarbe als Punkt vor dem Namen ─────────────────────────────────── */

.role-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 0.35rem;
  border-radius: 50%;
  background: var(--role, var(--muted));
  vertical-align: 0.12em;
  flex: none;
}

/* ── Einstellungen: Reiter oben, eine Spalte darunter ─────────────────────── */

@media (min-width: 720px) {
  .settings-shell {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.9rem;
  }
  .settings-nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem;
    padding: 0 0 0.75rem;
    border-bottom: 1px solid var(--line);
  }
  .settings-search { flex: 1 1 100%; margin: 0 0 0.35rem; }
  .settings-group { display: contents; }
  .settings-group__title { display: none; }
  .settings-row {
    width: auto;
    margin: 0;
    padding: 0.38rem 0.8rem 0.38rem 0.45rem;
    gap: 0.4rem;
    border-radius: 999px;
    font-size: 0.86rem;
    background: transparent;
  }
  .settings-row__ico { width: 1.45rem; height: 1.45rem; border-radius: 50%; background: rgba(255, 255, 255, 0.06); }
  .settings-row__ico .ico { width: 0.85rem; height: 0.85rem; }
  .settings-row__chev { display: none; }
  .settings-row.is-on {
    background: var(--grad-soft);
    border-color: rgba(141, 107, 255, 0.55);
  }
  .settings-row--danger { margin-left: auto; }
  .settings-panel-placeholder,
  .settings-shell.is-detail .settings-panel-placeholder { display: none; }
  .settings-panels {
    padding: 1rem 1.1rem;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.02);
  }
  .settings-panels .settings-panel.settings-block { background: transparent; border: 0; padding: 0; box-shadow: none; }
}
