body {
  margin: 0;
  font-family: 'Segoe UI', sans-serif;
  background: #23272a;
  color: #f6f6f6;
}

#app {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Header */
.server-header {
  background: #23272a;
  display: flex;
  align-items: center;
  padding: 10px 24px;
  box-shadow: 0 2px 8px #0001;
}
.server-logo {
  width: 48px;
  height: 48px;
  border-radius: 25%;
  margin-right: 14px;
}

/* Server window layout */
.server-window {
  flex: 1;
  display: flex;
  min-height: 0;
}

/* Channels sidebar */
.channels-list {
  background: #2c2f33;
  width: 240px;
  padding: 16px 8px 16px 16px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  border-right: 2px solid #2224;
}

.channels-list h2 {
  color: #b9bbbe;
  margin: 10px 0 5px 3px;
  font-size: 15px;
  letter-spacing: 0.5px;
}

.channels-list ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.channels-list li {
  padding: 7px 10px;
  border-radius: 4px;
  color: #fff;
  cursor: pointer;
  font-weight: 500;
  margin-bottom: 2px;
  transition: background 0.14s;
}

.channels-list li.active,
.channels-list li:hover {
  background: #3a3f4a;
}

.voice-list .voice-icon {
  margin-right: 5px;
}

/* Highlight Voice channel if active */
.voice-list li.active {
  background: #389eff44;
  color: #fff1bd;
}

/* MUSIC/VOICE SYSTEM UI */
.music-voice-queue {
  background: #232946;
  border-bottom: 2px solid #444a60;
  padding: 13px 22px 12px 22px;
  margin-bottom: 2px;
  border-radius: 0 0 12px 12px;
  box-shadow: 0 4px 16px #0037 0px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  animation: fadeIn 0.7s;
}
@keyframes fadeIn { from {opacity:0} to {opacity:1} }

.music-queue-header {
  display: flex;
  align-items: center;
  gap:10px;
  margin-bottom:6px;
  font-size: 15px;
  background:none;
  color:#EEE;
}
.ai-music-display {
  margin: 0;
}
.song-title {
  font-size: 16px;
  font-weight: bold;
  color: #b7e1ff;
  margin-bottom: 7px;
  display: block;
}
.ai-bots-row {
  display: flex;
  align-items: center;
  margin-top: 2px;
  margin-bottom: 4px;
}
.bot-avatar-music {
  object-fit: cover;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #223c5f;
  margin-right: 4px;
  border: 2px solid #1d2233;
  box-shadow: 0 0 5px #1122b82f;
  transition: scale 0.1s;
}
.user-music-upload-form {
  display: flex;
  align-items: center;
  gap: 4px;
}
.upload-label .upload-btn {
  background: #4b61fa;
  color: #fff;
  border-radius: 6px;
  font-size: 15px;
  font-weight: 600;
  padding: 8px 17px;
  cursor: pointer;
  display: inline-block;
  transition: background 0.15s;
  border: none;
}
.upload-label .upload-btn:hover {
  background: #3689ff;
}

/* User block at bottom */
.user-block {
  display: flex;
  align-items: center;
  margin-top: auto;
  background: #22262b;
  padding: 10px 8px;
  border-radius: 8px;
}

.user-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #222;
  margin-right: 9px;
}

.user-name {
  font-weight: bold;
  font-size: 16px;
}

/* Chat area */
.chat-area {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: #36393f;
  min-width: 0;
  min-height: 0;
  position: relative;
}

.channel-header {
  background: #383a40;
  padding: 0.8em 1em;
  border-bottom: 1px solid #292b2f;
  display: flex;
  align-items: baseline;
  gap: 14px;
}

.channel-header h2 {
  font-size: 20px;
  color: #fff;
  margin: 0;
}

.channel-header .topic {
  color: #aab0b6;
  font-size: 14px;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 18px 18px 4px 18px;
  display: flex;
  flex-direction: column;
  gap: 0.5em;
}

.chat-message {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  background: #39394222;
  border-radius: 7px;
  padding: 7px 12px;
}

.msg-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #1f1e23;
  margin-bottom: 3px;
}

.msg-user {
  font-weight: bold;
  margin-right: 8px;
}

.msg-content {
  /* take rest of space to wrap ok */
  flex: 1;
  word-break: break-word;
}

.msg-date {
  font-size: 12px;
  color: #888;
  margin-left: 8px;
}

.chat-input {
  border-top: 1.5px solid #292b2f;
  background: #383a40;
  padding: 12px 16px;
  display: flex;
  gap: 10px;
}

.chat-input input {
  flex: 1;
  border: none;
  border-radius: 5px;
  padding: 8px;
  background: #484b54;
  color: #f6f6f6;
  font-size: 15px;
}

.chat-input input:focus {
  outline: 2px solid #4b61fa77;
}

.chat-input button {
  background: linear-gradient(90deg,#4b61fa,#4bfad6);
  border: none;
  border-radius: 5px;
  padding: 8px 18px;
  color: #fff;
  font-weight: bold;
  font-size: 15px;
  cursor: pointer;
  transition: background 0.2s;
}

.chat-input button:disabled {
  background: #333;
  color: #999;
  cursor: not-allowed;
}

/* Custom emoji legend/info row */
.custom-emoji-legend {
  background: none;
  color: #ccc;
  font-size: 14px;
  padding: 7px 16px 2px 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.inline-emoji {
  display: inline-block;
  vertical-align: middle;
  height: 22px;
  width: 22px;
  object-fit: contain;
  margin-right: 2px;
  border-radius: 5px;
  background: #222;
  box-shadow: 0 0 1px #8886;
}

/* Ensure emoji looks good inside chat */
.msg-content .inline-emoji {
  margin: 0 2px;
  vertical-align: middle;
  height: 20px;
  width: 20px;
}

@media (max-width: 600px) {
  .server-window {
    flex-direction: column;
  }
  .channels-list {
    width: 100%;
    min-width: 0;
    flex-direction: row;
    padding: 6px 0 0 0;
    gap: 4px;
    border-right: none;
    border-bottom: 2px solid #2224;
    justify-content: flex-start;
    overflow-x: auto;
  }
  .channels-list h2,
  .channels-list ul,
  .user-block {
    display: none;
  }
  .channels-list li {
    display: inline-block;
    padding: 7px 14px;
    margin-bottom: 0;
  }
}