/* layout rev: floating channel panel */
:root {
  --bg-deep: #1e1f22;
  --bg-mid: #2c2e33;
  --bg-sidebar: #2c2e33;
  /* Chat column: slightly lighter than channel sidebar (Discord-style split) */
  --bg-chat: #36393f;
  --bg-chat-input: #4e5058;
  --bg-hover: #35373c;
  --settings-font-size: 16px;
  --accent: #5865f2;
  --accent-hover: #4752c4;
  --text: #f2f3f5;
  --muted: #949ba4;
  --danger: #ed4245;
  --success: #3ba55d;
  --radius: 8px;
  font-family: "Segoe UI", system-ui, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg-chat);
  color: var(--text);
  height: 100dvh;
  overflow: hidden;
}

.app {
  display: grid;
  grid-template-columns: 72px minmax(260px, 280px) 1fr;
  height: 100%;
  background: var(--bg-chat);
}

.servers {
  background: var(--bg-sidebar);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 12px;
  gap: 8px;
  position: relative;
}

.server-pill {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--guild-icon-bg, var(--accent));
  display: grid;
  place-items: center;
  font-weight: 700;
  cursor: default;
  overflow: hidden;
  padding: 6px;
}

.server-pill-logo {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  pointer-events: none;
  mix-blend-mode: lighten;
}

.guild-badge-img.guild-icon-custom,
.server-pill-logo.guild-icon-custom {
  object-fit: cover;
  mix-blend-mode: normal;
  border-radius: inherit;
}

.server-pill.active {
  border-radius: 16px;
}

.channels {
  background: var(--bg-sidebar);
  display: flex;
  flex-direction: column;
  min-height: 0;
  min-width: 0;
  overflow: hidden;
  margin: 3px 8px 4px 8px;
  border-radius: 14px;
  position: relative;
  z-index: 3;
  border: 1px solid rgba(255, 255, 255, 0.045);
  box-shadow:
    inset 1px 0 0 rgba(255, 255, 255, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 0 0 1px rgba(0, 0, 0, 0.5),
    -8px 0 28px rgba(0, 0, 0, 0.55),
    0 14px 36px rgba(0, 0, 0, 0.42),
    0 4px 14px rgba(0, 0, 0, 0.35);
  transform: translateZ(0);
}

.guild-hero {
  flex-shrink: 0;
  padding: 0 0 4px;
  border-bottom: none;
  box-shadow: none;
}

.guild-banner {
  position: relative;
  height: 124px;
  overflow: hidden;
  background-color: #0c0c0e;
  border-radius: 0;
  border: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: none;
}

/* Banner image fills inset card (cover) */
.guild-banner-media {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  pointer-events: none;
  z-index: 0;
}

.guild-banner:not(.has-image) .guild-banner-media {
  display: none;
}

.guild-banner-fade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.72) 0%, rgba(0, 0, 0, 0.35) 35%, transparent 65%);
  pointer-events: none;
  z-index: 1;
}

.guild-toolbar {
  position: absolute;
  left: 0;
  right: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 2px;
  padding: 6px 8px;
}

.guild-toolbar-top {
  top: 0;
  bottom: auto;
}

.guild-header-btn {
  display: flex;
  align-items: center;
  flex: 0 1 auto;
  max-width: 100%;
  min-width: 0;
  min-height: 32px;
  max-height: 36px;
  padding: 6px 8px;
  margin: 0;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: #fff;
  font: 600 15px/1.2 "gg sans", "Noto Sans", "Segoe UI", system-ui, sans-serif;
  cursor: pointer;
  text-align: left;
  transition:
    background-color 0.12s ease-out,
    box-shadow 0.12s ease-out;
}

.guild-header-btn:hover,
.guild-header-btn[aria-expanded="true"] {
  background: rgba(64, 66, 73, 0.92);
  box-shadow: 0 1px 0 rgba(4, 4, 5, 0.2);
}

.guild-header-btn[aria-expanded="true"] {
  background: rgba(53, 55, 60, 0.95);
}

.guild-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  min-width: 20px;
  opacity: 1;
  flex-shrink: 0;
  margin-right: 6px;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.65));
}

.guild-badge-img {
  display: block;
  width: 20px;
  height: 20px;
  object-fit: contain;
  border-radius: 4px;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.65));
  mix-blend-mode: lighten;
}

.guild-badge-img.guild-icon-custom {
  border-radius: 4px;
}

.guild-title {
  flex: 0 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  letter-spacing: 0.01em;
}

.guild-chevron {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  min-width: 16px;
  opacity: 1;
  color: #f2f3f5;
  flex-shrink: 0;
  margin-left: 2px;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.65));
}

.guild-header-btn[aria-expanded="true"] .guild-chevron svg {
  transform: rotate(180deg);
}

.guild-title {
  color: #fff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.75);
}

.guild-invite-wrap {
  position: relative;
  flex-shrink: 0;
  margin-left: auto;
}

.guild-invite-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 4px;
  background: transparent;
  color: #f2f3f5;
  cursor: pointer;
  transition: background 0.12s ease, color 0.12s ease;
}

.guild-invite-btn:hover {
  background: rgba(0, 0, 0, 0.45);
  color: #fff;
}

.guild-invite-img,
.invite-icon-img {
  display: block;
  width: 22px;
  height: 22px;
  object-fit: contain;
  pointer-events: none;
  mix-blend-mode: lighten;
  filter: drop-shadow(0 1px 1px rgba(0, 0, 0, 0.5));
}

.srv-drop-icon .invite-icon-img {
  width: 20px;
  height: 20px;
}

.guild-invite-wrap:hover .guild-invite-tooltip,
.guild-invite-btn:focus-visible + .guild-invite-tooltip {
  opacity: 1;
  visibility: visible;
}

.guild-invite-tooltip {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  white-space: nowrap;
  padding: 6px 10px;
  background: #111214;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  border-radius: 4px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.45);
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.12s ease;
  z-index: 20;
}

.guild-invite-tooltip::before {
  content: "";
  position: absolute;
  bottom: 100%;
  right: 10px;
  border: 5px solid transparent;
  border-bottom-color: #111214;
}

.guild-header-btn .guild-chevron svg {
  transition: transform 0.15s ease;
}

.categories-scroll {
  flex: 1;
  overflow-x: hidden;
  overflow-y: auto;
  padding: 6px 8px 12px;
  min-height: 0;
  min-width: 0;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.categories-scroll::-webkit-scrollbar {
  width: 0;
  height: 0;
  display: none;
}

.category-block {
  margin-bottom: 4px;
}

.category-header {
  display: flex;
  align-items: center;
  height: 24px;
  margin: 8px 0 2px;
  padding: 0 4px 0 2px;
  gap: 0;
  user-select: none;
}

.category-header:hover .category-add {
  opacity: 1;
}

.category-chevron,
.category-title {
  border: none;
  background: transparent;
  color: #949ba4;
  cursor: pointer;
  font: 600 12px/1 "Segoe UI", system-ui, sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.category-chevron {
  display: flex;
  width: 20px;
  height: 20px;
  align-items: center;
  justify-content: center;
  padding: 0;
  flex-shrink: 0;
  transition: transform 0.15s ease;
}

.category-block.is-collapsed .category-chevron {
  transform: rotate(-90deg);
}

.category-title {
  flex: 1;
  min-width: 0;
  text-align: left;
  padding: 0 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.category-title:hover,
.category-chevron:hover {
  color: #dbdee1;
}

.category-add-wrap {
  position: relative;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.category-add {
  width: 20px;
  height: 20px;
  border: none;
  background: transparent;
  color: #949ba4;
  font-size: 16px;
  line-height: 1;
  padding: 0;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.1s ease, color 0.1s ease;
}

.category-header:hover .category-add,
.category-add:focus {
  opacity: 1;
}

.category-add:hover {
  color: #dbdee1;
}

.category-tooltip {
  position: fixed;
  z-index: 20000;
  white-space: nowrap;
  padding: 6px 10px;
  background: #111214;
  color: #f2f3f5;
  font-size: 13px;
  font-weight: 600;
  border-radius: 5px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.45);
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transform: translate(-100%, calc(-100% - 8px));
  transition: opacity 0.12s ease;
}

.category-tooltip.is-on {
  opacity: 1;
  visibility: visible;
}

.category-tooltip::after {
  content: "";
  position: absolute;
  top: 100%;
  right: 8px;
  border: 5px solid transparent;
  border-top-color: #111214;
}

.category-channels {
  list-style: none;
  margin: 0;
  padding: 0 8px;
}

.channel-section {
  padding: 12px 8px 0;
}

.channel-section h2 {
  margin: 0 8px 6px;
  font-size: 0.68rem;
  text-transform: uppercase;
  color: var(--muted);
  letter-spacing: 0.04em;
}

.channels ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.channel-row {
  border-radius: 4px;
  transition: background 0.1s ease, box-shadow 0.1s ease;
}

.channel-row.voice-drop-over {
  background: rgba(35, 165, 89, 0.32);
  box-shadow: inset 0 0 0 1px rgba(35, 165, 89, 0.85);
}

.channel-row.connected-voice > .channel-btn {
  color: #23a559;
}

.channels li button {
  width: 100%;
  text-align: left;
  border: none;
  background: transparent;
  color: var(--muted);
  padding: 6px 8px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  gap: 6px;
}

.channel-btn .ch-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ch-ico-wrap {
  position: relative;
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ch-hash {
  font-weight: 700;
  font-size: 16px;
  line-height: 1;
  color: inherit;
}

.ch-ico {
  display: block;
}

.ch-lock {
  position: absolute;
  right: -3px;
  bottom: -2px;
  width: 9px;
  height: 9px;
  background: #2b2d31;
  border-radius: 2px;
  color: #b5bac1;
}

.voice-user-list {
  list-style: none;
  margin: 0;
  padding: 0 0 4px 8px;
}

.voice-user {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 32px;
  padding: 0 8px 0 28px;
  border-radius: 4px;
  color: #f2f3f5;
  cursor: grab;
  user-select: none;
}

.voice-user:hover {
  background: rgba(79, 84, 92, 0.32);
}

.voice-user.dragging {
  opacity: 0.4;
}

.voice-user-av {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.voice-user-name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 14px;
}

.voice-user-tag {
  flex-shrink: 0;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #b5bac1;
  background: #1e1f22;
  border: 1px solid #3f4147;
  border-radius: 4px;
  padding: 1px 4px;
}

.channels li button:hover {
  background: var(--bg-hover);
  color: var(--text);
}

.channels li button.active {
  background: var(--bg-hover);
  color: var(--text);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.channel-dock {
  margin-top: auto;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
  min-width: 0;
  overflow: hidden;
  position: relative;
  z-index: 4;
  padding: 8px 8px 10px;
  background: transparent;
  border-top: 1px solid rgba(0, 0, 0, 0.22);
  border-radius: 0;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

/* Voice connection strip (sits directly above user panel) */
.voice-connection {
  flex-shrink: 0;
  width: auto;
  max-width: calc(100% - 16px);
  margin: 0 8px;
  padding: 8px 10px 10px;
  border-radius: 8px;
  background: linear-gradient(180deg, #2e3035 0%, #292a2f 55%, #27282c 100%);
  border: none;
  box-shadow:
    0 4px 14px rgba(0, 0, 0, 0.32),
    0 1px 3px rgba(0, 0, 0, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
  box-sizing: border-box;
  overflow: hidden;
  position: relative;
  z-index: 1;
}

.voice-connection.hidden {
  display: none;
}

.voice-connection-status {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.vc-signal {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  background: linear-gradient(180deg, #243d32 0%, #1e3328 100%);
  border: 1px solid rgba(35, 165, 89, 0.25);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 2px 4px rgba(0, 0, 0, 0.25);
  flex-shrink: 0;
}

.vc-info {
  flex: 1;
  min-width: 0;
}

.vc-title {
  color: #23a559;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
}

.vc-sub {
  color: #b5bac1;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.25;
  white-space: normal;
  word-break: break-word;
  cursor: pointer;
}

.vc-end-actions {
  display: flex;
  align-items: center;
  gap: 2px;
  flex-shrink: 0;
}

.vc-icon-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 4px;
  background: transparent;
  color: #b5bac1;
  cursor: pointer;
  transition:
    background 0.12s ease,
    color 0.12s ease,
    box-shadow 0.12s ease;
}

.vc-icon-btn:hover:not(:disabled) {
  background: #3f4147;
  color: #fff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.vc-icon-btn:disabled {
  opacity: 0.45;
  cursor: default;
}

.vc-disconnect:hover {
  background: #3f4147;
  color: #fff;
}

.voice-connection-tools {
  display: flex;
  gap: 6px;
  margin-top: 8px;
  min-width: 0;
}

.vc-tool {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  max-height: 32px;
  padding: 0;
  border: 1px solid rgba(0, 0, 0, 0.28);
  border-radius: 8px;
  background: linear-gradient(180deg, #313338 0%, #2b2d31 100%);
  color: #dbdee1;
  cursor: pointer;
  box-shadow:
    0 2px 4px rgba(0, 0, 0, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
  transition:
    background 0.12s ease,
    box-shadow 0.12s ease,
    transform 0.12s ease;
}

.vc-tool svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.vc-tool:hover:not(:disabled) {
  background: linear-gradient(180deg, #3a3c41 0%, #35373c 100%);
  color: #fff;
  box-shadow:
    0 3px 6px rgba(0, 0, 0, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.07);
}

.vc-tool:active:not(:disabled) {
  transform: translateY(1px);
  box-shadow:
    0 1px 2px rgba(0, 0, 0, 0.3),
    inset 0 1px 2px rgba(0, 0, 0, 0.2);
}

.vc-tool:disabled {
  opacity: 0.55;
  cursor: default;
}

.vc-tool.is-on {
  background: #23a559;
  color: #fff;
  border-color: #1a7f40;
}

.voice-stage {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.voice-tile {
  position: relative;
  background: #1e1f22;
  border-radius: 12px;
  overflow: hidden;
  min-height: 140px;
}

.voice-tile video {
  width: 100%;
  height: 180px;
  object-fit: cover;
  background: #111;
}

.voice-tile-name {
  position: absolute;
  left: 10px;
  bottom: 8px;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  text-shadow: 0 1px 4px #000;
}

.voice-activity-frame {
  width: 100%;
  min-height: 360px;
  border: none;
  border-radius: 12px;
  margin-bottom: 12px;
  background: #000;
}

.vc-pop {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 72px;
  z-index: 20;
  background: #111214;
  border: 1px solid #3f4147;
  border-radius: 8px;
  padding: 12px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
}

.vc-pop header {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #b5bac1;
  margin-bottom: 10px;
}

.vc-sound-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.vc-sound-btn,
.vc-activity-item {
  border: none;
  border-radius: 8px;
  background: #2b2d31;
  color: #f2f3f5;
  padding: 10px 12px;
  text-align: left;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  text-transform: capitalize;
}

.vc-sound-btn:hover,
.vc-activity-item:hover {
  background: #3f4147;
}

#server-chat-shell.voice-chat-open #messages {
  position: absolute;
  right: 12px;
  top: 52px;
  bottom: 72px;
  width: min(360px, 42%);
  z-index: 8;
  background: rgba(30, 31, 34, 0.92);
  border-radius: 8px;
  display: flex;
}

#server-chat-shell.voice-chat-open #composer {
  position: absolute;
  right: 12px;
  bottom: 12px;
  width: min(360px, 42%);
  z-index: 9;
  background: transparent;
}

/* Discord-style user panel */
.user-panel {
  margin: 0 8px;
  display: flex;
  align-items: flex-start;
  gap: 6px;
  min-height: 52px;
  padding: 8px 8px 8px 10px;
  border-radius: 8px;
  background: linear-gradient(180deg, #2a2b30 0%, #25262a 45%, #232428 100%);
  border: none;
  box-shadow:
    0 6px 16px rgba(0, 0, 0, 0.38),
    0 2px 6px rgba(0, 0, 0, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  position: relative;
  z-index: 2;
}

.user-panel-avatar {
  position: relative;
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  margin-top: 2px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  overflow: visible;
}

.user-panel-avatar-img {
  display: block;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  background: #1e1f22;
  mix-blend-mode: lighten;
}

.user-status-dot {
  position: absolute;
  right: -3px;
  bottom: -3px;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  border: 3px solid #232428;
  background: radial-gradient(circle at 32% 28%, #aeb2ba 0%, #80848e 55%, #6d7179 100%);
  box-sizing: content-box;
  box-shadow:
    0 2px 5px rgba(0, 0, 0, 0.5),
    0 0 0 1px rgba(0, 0, 0, 0.15),
    inset 0 1px 1px rgba(255, 255, 255, 0.35),
    inset 0 -2px 2px rgba(0, 0, 0, 0.2);
  z-index: 3;
}

.user-status-dot.online {
  background: radial-gradient(circle at 32% 28%, #3ecf7a 0%, #23a559 55%, #1a7d43 100%);
}

.user-status-dot.idle {
  background: #f0b232;
}

.user-panel-identity {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.user-panel-name {
  width: 100%;
  max-width: 100%;
  padding: 0;
  border: none;
  background: transparent;
  color: #f2f3f5;
  font: 600 14px/1.25 "gg sans", "Noto Sans", "Segoe UI", system-ui, sans-serif;
  field-sizing: content;
  min-width: 6ch;
}

.user-panel-name:hover,
.user-panel-name:focus {
  outline: none;
  background: rgba(0, 0, 0, 0.12);
  border-radius: 2px;
}

.user-panel-name::placeholder {
  color: #949ba4;
  font-weight: 500;
}

.user-panel-activity {
  display: flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
  color: #949ba4;
  font-size: 11px;
  font-weight: 500;
  line-height: 1.2;
}

.user-activity-icon {
  display: flex;
  flex-shrink: 0;
}

.user-activity-text {
  white-space: normal;
  word-break: break-word;
  line-height: 1.25;
}

.user-panel-controls {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  margin-top: 2px;
  margin-left: auto;
}

.user-panel .user-ctl-chev {
  display: none;
}

.user-ctl-wrap {
  display: flex;
  align-items: center;
}

.user-ctl-btn {
  display: flex;
  align-items: center;
  gap: 0;
  height: 32px;
  padding: 0 4px;
  border: none;
  border-radius: 4px;
  background: transparent;
  color: #b5bac1;
  cursor: pointer;
}

.user-ctl-btn:hover {
  background: #3f4147;
  color: #fff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.user-ctl-btn.is-active {
  background: #3f4147;
  color: #f23f43;
}

.user-ctl-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
}

.user-ctl-icon .ico-mic-off,
.user-ctl-icon .ico-headphones-off {
  display: none;
}

.user-ctl-btn.is-active .ico-mic,
.user-ctl-btn.is-active .ico-headphones {
  display: none;
}

.user-ctl-btn.is-active .ico-mic-off,
.user-ctl-btn.is-active .ico-headphones-off {
  display: block;
}

.user-ctl-chev {
  display: flex;
  align-items: center;
  opacity: 0.85;
}

.user-ctl-settings {
  width: 32px;
  justify-content: center;
  padding: 0;
}

.dot.on {
  background: var(--success);
}

.dot.off {
  background: var(--muted);
}

.main {
  display: flex;
  flex-direction: column;
  min-height: 0;
  background: var(--bg-chat);
  position: relative;
  overflow: hidden;
}

.main-head {
  padding: 12px 16px;
  border-bottom: 1px solid #26272b;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-weight: 600;
}

.messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: transparent;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.messages::-webkit-scrollbar {
  width: 0;
  height: 0;
  display: none;
}

.msg {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 4px 8px 4px 12px;
  margin: 0 -8px;
  border-radius: 0;
  position: relative;
}

.msg:hover {
  background: rgba(255, 255, 255, 0.03);
}

.msg.msg-ctx-on {
  background: rgba(255, 255, 255, 0.08);
}

.msg .author {
  cursor: pointer;
}

.msg .author:hover {
  text-decoration: underline;
}

.msg-reacts {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 6px;
}

.msg-react-chip {
  border: 1px solid #3f4147;
  background: #2b2d31;
  color: #dbdee1;
  border-radius: 8px;
  padding: 0 6px;
  height: 24px;
  font-size: 12px;
  cursor: pointer;
}

.msg-react-chip.on {
  background: rgba(88, 101, 242, 0.2);
  border-color: #5865f2;
}

.msg-react-row {
  display: flex;
  gap: 8px;
  padding: 4px 4px 10px;
}

.msg-react-quick {
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 8px;
  background: #2b2d31;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}

.msg-react-quick:hover {
  background: #3f4147;
}

.msg-ctx-menu {
  width: 300px;
  min-width: 300px;
  max-width: 300px;
  padding: 8px;
  border-radius: 8px;
  background: #111214;
}

.msg-ctx-item {
  justify-content: flex-start !important;
  gap: 8px;
  padding: 6px 8px;
  min-height: 32px;
  border-radius: 4px;
  font-weight: 500;
  font-size: 14px;
  color: #dbdee1;
}

.msg-ctx-ico {
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: #b5bac1;
}

.msg-ctx-lab {
  flex: 1;
  text-align: left;
}

.msg-ctx-item .ctx-chevron {
  margin-left: auto;
  color: #b5bac1;
}

.msg-ctx-item:hover .msg-ctx-ico,
.msg-ctx-item:hover .ctx-chevron {
  color: #fff;
}

.msg .avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--accent);
  display: grid;
  place-items: center;
  font-weight: 600;
  flex-shrink: 0;
  overflow: hidden;
  cursor: pointer;
}

.msg .avatar:hover {
  box-shadow: 0 0 0 2px rgba(88, 101, 242, 0.55);
}

.msg .avatar.has-pfp {
  background: #1e1f22;
  padding: 0;
}

.msg .avatar .avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 50%;
}

.msg .body .author {
  font-weight: 600;
  font-size: 0.9rem;
}

.msg .body .time {
  color: var(--muted);
  font-size: 0.75rem;
  margin-left: 8px;
}

.msg .body .content {
  margin-top: 2px;
  line-height: 1.4;
  word-break: break-word;
  font-size: var(--settings-font-size, 16px);
}

.msg .body .content a.msg-link {
  color: #00a8fc;
  text-decoration: none;
}

.msg .body .content a.msg-link:hover {
  text-decoration: underline;
}

.compact-chat .messages {
  gap: 2px;
}

.compact-chat .msg {
  gap: 8px;
}

.compact-chat .msg .avatar {
  width: 32px;
  height: 32px;
  font-size: 0.8rem;
}

html[data-theme="darker"] {
  --bg-deep: #161719;
  --bg-mid: #232428;
  --bg-chat: #313338;
  --bg-chat-input: #4e5058;
  --bg-hover: #2e3035;
}

html[data-theme="amoled"] {
  --bg-deep: #000;
  --bg-mid: #0a0a0a;
  --bg-chat: #111214;
  --bg-chat-input: #2b2d31;
  --bg-hover: #1a1a1a;
}

html.high-contrast .msg .body .content,
html.high-contrast .msg .body .author {
  color: #fff;
  font-weight: 500;
}

html.reduce-motion *,
html.reduce-motion *::before,
html.reduce-motion *::after {
  animation-duration: 0.01ms !important;
  animation-iteration-count: 1 !important;
  transition-duration: 0.01ms !important;
}

.msg img.attach {
  margin-top: 8px;
  max-width: 420px;
  border-radius: var(--radius);
}

.voice-panel {
  flex: 1;
  padding: 24px;
  color: var(--muted);
  background: var(--bg-chat);
}

.voice-panel ul {
  list-style: none;
  padding: 0;
}

.voice-panel li {
  padding: 8px 0;
}

.composer {
  padding: 0 16px 24px;
  background: var(--bg-chat);
}

.composer-bar {
  display: flex;
  align-items: center;
  min-height: 44px;
  background: var(--bg-chat-input);
  border-radius: 8px;
  padding: 1px 4px 1px 0;
}

.composer-attach {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  margin-left: 4px;
  padding: 0;
  border: none;
  border-radius: 4px;
  background: transparent;
  color: #b5bac1;
  cursor: pointer;
  transition: color 0.1s ease;
}

.composer-attach:hover {
  color: #dbdee1;
}

.composer-input {
  flex: 1;
  min-width: 0;
  border: none;
  outline: none;
  background: transparent;
  color: #dbdee1;
  font-size: 1rem;
  line-height: 1.375rem;
  padding: 11px 8px 11px 0;
  font-family: inherit;
}

.composer-input::placeholder {
  color: #b5bac1;
}

.composer-trailing {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  gap: 2px;
  padding-right: 2px;
}

.composer-ico {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: none;
  border-radius: 4px;
  background: transparent;
  color: #b5bac1;
  cursor: pointer;
}

.composer-ico:not(:disabled) {
  cursor: pointer;
}

.composer-ico:not(:disabled):hover {
  color: #dbdee1;
}

.composer-ico svg {
  display: block;
}

.composer-ico-gif {
  width: auto;
  min-width: 30px;
  padding: 0 3px;
}

.composer-gif-label {
  display: block;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1;
  color: #b5bac1;
  border: 1.5px solid #b5bac1;
  border-radius: 3px;
  padding: 3px 4px;
}

.hidden {
  display: none !important;
}

.ctx-layer {
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
}

.ctx-layer:not(.hidden) {
  pointer-events: auto;
}

.ctx-menu,
.ctx-submenu {
  pointer-events: auto;
}

.ctx-menu {
  position: fixed;
  min-width: 188px;
  max-width: 320px;
  width: max-content;
  padding: 6px 8px;
  background: #111214;
  border-radius: 4px;
  box-shadow:
    0 8px 16px rgba(0, 0, 0, 0.24),
    0 0 2px rgba(0, 0, 0, 0.4);
  font-size: 14px;
  font-weight: 500;
  color: #dbdee1;
}

.ctx-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  gap: 8px;
  padding: 6px 10px;
  min-height: 32px;
  border: none;
  border-radius: 2px;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
  font: inherit;
  position: relative;
}

.ctx-item:hover:not(.ctx-disabled):not(.ctx-muted) {
  background: #4752c4;
  color: #fff;
}

.ctx-item.ctx-muted {
  color: #949ba4;
  font-weight: 400;
}

.ctx-item.ctx-muted:hover {
  background: #4752c4;
  color: #fff;
}

.ctx-item.ctx-danger {
  color: #f23f43;
}

.ctx-item.ctx-danger:hover {
  background: #f23f43;
  color: #fff;
}

.ctx-item.ctx-has-leading {
  gap: 10px;
}

.ctx-leading {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  color: #b5bac1;
}

.ctx-item:hover .ctx-leading {
  color: #fff;
}

.ctx-plain-label {
  flex: 1;
  text-align: left;
}

.mod-view {
  position: fixed;
  inset: 0;
  z-index: 10001;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.65);
  padding: 24px;
}

.mod-view.hidden {
  display: none;
}

.mod-view-card {
  width: min(420px, 100%);
  background: #313338;
  border-radius: 8px;
  padding: 0;
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.4);
}

.mod-view-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid #1e1f22;
}

.mod-view-head h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
  color: #f2f3f5;
}

.mod-view-dl {
  margin: 0;
  padding: 16px 20px 20px;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px 16px;
  font-size: 14px;
  color: #dbdee1;
}

.mod-view-dl dt {
  color: #949ba4;
  font-weight: 500;
}

.mod-view-dl dd {
  margin: 0;
  font-weight: 500;
}

.mod-view-mono {
  font-family: ui-monospace, Consolas, monospace;
  font-size: 13px;
  word-break: break-all;
}

.user-ctx-menu {
  min-width: 220px;
}

.ctx-id-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: -0.02em;
  border: 1px solid currentColor;
  border-radius: 2px;
  line-height: 1;
}

.channels li button.channel-btn.active {
  background: var(--bg-hover);
  color: var(--text);
}

.ctx-item.ctx-invite {
  color: #949cf7;
}

.ctx-item.ctx-invite:hover {
  color: #fff;
}

.ctx-item.ctx-disabled {
  opacity: 0.45;
  cursor: default;
}

.ctx-divider {
  height: 1px;
  margin: 4px 6px;
  background: #1e1f22;
}

.ctx-label {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
}

.ctx-hint {
  font-size: 12px;
  font-weight: 400;
  color: #949ba4;
}

.ctx-item:hover .ctx-hint {
  color: rgba(255, 255, 255, 0.75);
}

.ctx-chevron {
  display: flex;
  color: #b5bac1;
  opacity: 0.85;
  line-height: 0;
  margin-right: -2px;
}

.ctx-item:hover .ctx-chevron {
  color: #fff;
}

.ctx-has-check .ctx-check {
  width: 18px;
  height: 18px;
  border: 1px solid #4e5058;
  border-radius: 3px;
  flex-shrink: 0;
  background: transparent;
}

.ctx-has-check .ctx-check.on {
  background: #fff;
  border-color: #fff;
  box-shadow: inset 0 0 0 2px #111214;
}

.ctx-submenu {
  display: none;
  position: absolute;
  left: calc(100% - 4px);
  top: -6px;
  min-width: 200px;
  padding: 6px;
  background: #111214;
  border-radius: 4px;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.24);
  z-index: 1;
}

.ctx-submenu.flip {
  left: auto;
  right: calc(100% - 4px);
}

.ctx-parent:hover > .ctx-submenu,
.ctx-submenu.open {
  display: block;
}

.ctx-submenu .ctx-item {
  font-weight: 500;
}

.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10000;
  padding: 10px 16px;
  background: #111214;
  border: 1px solid #1e1f22;
  border-radius: 8px;
  color: #f2f3f5;
  font-size: 14px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
  pointer-events: none;
}

.server-pill {
  cursor: pointer;
  user-select: none;
}

/* Left-click server dropdown (icon list) */
.srv-dropdown {
  position: fixed;
  min-width: 220px;
  width: 248px;
  padding: 6px 8px;
  background: #111214;
  border-radius: 4px;
  box-shadow:
    0 8px 16px rgba(0, 0, 0, 0.24),
    0 0 2px rgba(0, 0, 0, 0.4);
  font-size: 14px;
  font-weight: 500;
  color: #dbdee1;
  pointer-events: auto;
}

.srv-drop-divider {
  height: 1px;
  margin: 4px 4px;
  background: #1e1f22;
}

.srv-drop-item {
  display: flex;
  align-items: center;
  width: 100%;
  gap: 8px;
  padding: 6px 8px;
  min-height: 36px;
  border: none;
  border-radius: 2px;
  background: transparent;
  color: #dbdee1;
  text-align: left;
  cursor: pointer;
  font: 500 14px/1.2 "Segoe UI", system-ui, sans-serif;
  position: relative;
}

.srv-drop-item:hover {
  background: #4752c4;
  color: #fff;
}

.srv-drop-item.srv-drop-danger {
  color: #f23f43;
}

.srv-drop-item.srv-drop-danger:hover {
  background: #f23f43;
  color: #fff;
}

.srv-drop-item.srv-drop-danger:hover .srv-drop-icon {
  color: #fff;
}

.srv-drop-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: #b5bac1;
}

.srv-drop-item:hover .srv-drop-icon {
  color: #fff;
}

.srv-drop-label {
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.srv-drop-chevron {
  display: flex;
  color: #b5bac1;
  margin-left: auto;
}

.srv-drop-item:hover .srv-drop-chevron {
  color: #fff;
}

.srv-drop-check {
  width: 18px;
  height: 18px;
  border: 1px solid #4e5058;
  border-radius: 3px;
  flex-shrink: 0;
  margin-left: auto;
}

.srv-drop-check.on {
  background: #fff;
  border-color: #fff;
  box-shadow: inset 0 0 0 2px #111214;
}

.srv-drop-parent > .srv-flyout {
  top: -4px;
}

.guild-header-btn {
  user-select: none;
}

.ctx-plain-label {
  flex: 1;
}

/* Create Channel modal */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 10001;
  background: rgba(0, 0, 0, 0.65);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.modal-backdrop.hidden {
  display: none !important;
}

.modal-card {
  width: 100%;
  max-width: 440px;
  max-height: 90vh;
  overflow-y: auto;
  background: #313338;
  border-radius: 8px;
  padding: 16px 16px 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.45);
  color: #f2f3f5;
}

.modal-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 12px;
}

.modal-head h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
}

.modal-sub {
  margin: 4px 0 0;
  font-size: 12px;
  color: #b5bac1;
  font-weight: 500;
}

.modal-close {
  border: none;
  background: transparent;
  color: #b5bac1;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  padding: 4px;
}

.modal-close:hover {
  color: #fff;
}

.modal-label {
  margin: 14px 0 8px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  color: #b5bac1;
  letter-spacing: 0.04em;
}

.type-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.type-opt {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 10px;
  border-radius: 6px;
  cursor: pointer;
  border: 1px solid transparent;
}

.type-opt:not(.disabled):hover {
  background: #2b2d31;
}

.type-opt.selected {
  background: #404249;
}

.type-opt.disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.type-radio {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid #4e5058;
  flex-shrink: 0;
  margin-top: 2px;
  position: relative;
}

.type-radio.on {
  border-color: #5865f2;
}

.type-radio.on::after {
  content: "";
  position: absolute;
  inset: 3px;
  background: #5865f2;
  border-radius: 50%;
}

.type-body strong {
  display: block;
  font-size: 15px;
  margin-bottom: 2px;
}

.type-desc {
  display: block;
  font-size: 12px;
  color: #949ba4;
  line-height: 1.35;
}

.modal-name-wrap {
  display: flex;
  align-items: center;
  background: #1e1f22;
  border: 1px solid #5865f2;
  border-radius: 4px;
  padding: 0 10px;
  margin-bottom: 14px;
}

.modal-hash {
  color: #949ba4;
  font-size: 16px;
  font-weight: 600;
  flex-shrink: 0;
}

.modal-emoji-btn {
  color: #b5bac1;
  font-size: 18px;
  line-height: 1;
  user-select: none;
}

.modal-select {
  width: 100%;
  height: 40px;
  margin-bottom: 14px;
  border: none;
  border-radius: 4px;
  background: #1e1f22;
  color: #f2f3f5;
  padding: 0 10px;
  font: inherit;
  outline: none;
}

.modal-btn.primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.modal-name-wrap input {
  flex: 1;
  border: none;
  background: transparent;
  color: #f2f3f5;
  padding: 10px 8px;
  font-size: 15px;
  outline: none;
}

.modal-private {
  display: block;
  margin: 8px 0 16px;
  cursor: pointer;
}

.modal-private-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 4px;
}

.toggle-track {
  width: 40px;
  height: 22px;
  background: #4e5058;
  border-radius: 11px;
  position: relative;
  transition: background 0.15s;
}

.toggle-track::after {
  content: "";
  position: absolute;
  width: 18px;
  height: 18px;
  top: 2px;
  left: 2px;
  background: #fff;
  border-radius: 50%;
  transition: transform 0.15s;
}

.toggle-track.on {
  background: #5865f2;
}

.toggle-track.on::after {
  transform: translateX(18px);
}

.modal-foot {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.modal-btn {
  border: none;
  border-radius: 4px;
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
}

.modal-btn.secondary {
  background: transparent;
  color: #f2f3f5;
}

.modal-btn.secondary:hover {
  text-decoration: underline;
}

.modal-btn.primary {
  background: #5865f2;
  color: #fff;
}

.modal-btn.primary:hover {
  background: #4752c4;
}

/* Discord-style Invite friends panel */
#invite-modal {
  z-index: 10020;
}

.inv-card {
  width: 100%;
  max-width: 440px;
  background: #313338;
  border-radius: 4px;
  padding: 16px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.55);
  color: #f2f3f5;
}

.inv-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 16px;
}

.inv-head h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: #f2f3f5;
}

.inv-sub {
  margin: 4px 0 0;
  font-size: 12px;
  color: #b5bac1;
  font-weight: 500;
}

.inv-land-ch {
  color: #dbdee1;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.inv-search-wrap {
  position: relative;
  display: block;
  margin-bottom: 8px;
}

.inv-search-ico {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  color: #b5bac1;
  pointer-events: none;
}

.inv-search-wrap input {
  width: 100%;
  height: 40px;
  border: none;
  border-radius: 4px;
  background: #1e1f22;
  color: #dbdee1;
  padding: 0 12px 0 36px;
  font-size: 16px;
  outline: none;
}

.inv-search-wrap input::placeholder {
  color: #6d6f78;
}

.inv-friend-list {
  list-style: none;
  margin: 0 0 16px;
  padding: 4px 0;
  max-height: 248px;
  overflow-y: auto;
  scrollbar-width: none;
}

.inv-friend-list::-webkit-scrollbar {
  display: none;
}

.inv-empty {
  padding: 16px 8px;
  text-align: center;
  color: #949ba4;
  font-size: 14px;
}

.inv-friend {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px;
  border-radius: 4px;
}

.inv-friend:hover {
  background: #2e3035;
}

.inv-av {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  background: #5865f2;
}

.inv-meta {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.inv-name {
  font-size: 16px;
  font-weight: 600;
  color: #f2f3f5;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.inv-handle {
  font-size: 12px;
  color: #949ba4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.inv-btn {
  flex-shrink: 0;
  min-width: 72px;
  height: 32px;
  border: none;
  border-radius: 3px;
  background: #4e5058;
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  padding: 0 16px;
}

.inv-btn:hover {
  background: #6d6f78;
}

.inv-btn.sent,
.inv-btn:disabled {
  background: transparent;
  color: #23a559;
  cursor: default;
  font-weight: 600;
}

.inv-or {
  margin: 0 0 8px;
  font-size: 12px;
  color: #b5bac1;
}

.inv-link-row {
  display: flex;
  gap: 12px;
  align-items: stretch;
}

.inv-link {
  flex: 1;
  min-width: 0;
  height: 40px;
  border: none;
  border-radius: 4px;
  background: #1e1f22;
  color: #dbdee1;
  padding: 0 12px;
  font-size: 16px;
  outline: none;
}

.inv-copy {
  flex-shrink: 0;
  min-width: 74px;
  height: 40px;
  border: none;
  border-radius: 3px;
  background: #5865f2;
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  padding: 0 16px;
}

.inv-copy:hover {
  background: #4752c4;
}

.inv-expire {
  margin: 8px 0 0;
  font-size: 12px;
  color: #b5bac1;
}

.inv-expire a {
  color: #00a8fc;
  text-decoration: none;
}

.inv-expire a:hover {
  text-decoration: underline;
}

html[data-layout="black"] {
  --bg-deep: #05060a;
  --bg-mid: #07080c;
  --bg-sidebar: #07080c;
  --bg-chat: #07080c;
  --bg-chat-input: #16171c;
  --bg-hover: #121318;
}

html[data-layout="black"] body,
html[data-layout="black"] .app {
  background: #07080c;
}

html[data-layout="black"] .user-panel {
  background: linear-gradient(180deg, #121318 0%, #0c0d12 100%);
}

html[data-layout="black"] .main-head {
  border-bottom-color: #15161a;
}

.guild-float-fx {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}

.servers > *:not(.guild-float-fx),
.channels > *:not(.guild-float-fx),
#server-chat-shell > *:not(.guild-float-fx) {
  position: relative;
  z-index: 1;
}

.guild-float-fx.is-chat .guild-float-logo {
  mix-blend-mode: overlay;
}

.guild-float-logo {
  position: absolute;
  object-fit: contain;
  mix-blend-mode: screen;
  animation-name: auth-float;
  animation-timing-function: ease-in-out;
  animation-iteration-count: infinite;
}

@keyframes auth-float {
  0%,
  100% {
    transform: translate3d(0, 0, 0) rotate(0deg);
  }
  50% {
    transform: translate3d(var(--drift-x), var(--drift-y), 0) rotate(var(--spin));
  }
}