/* Tournament chat styling */

/* Chat container */
#ChatContainer {
  margin-top: 1.5rem;
}

/* Chat messages area */
#ChatMessages {
  height: 480px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 1rem;
  scroll-behavior: auto;
  background-color: #1a1a1a;
  border-radius: 0.375rem;
}

/* Message box for other users */
.message-box-start {
  border-top-left-radius: 1rem;
  border-top-right-radius: 1rem;
  border-bottom-right-radius: 1rem;
  background-color: #2b2b2b;
  color: white;
  word-wrap: break-word;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Message box for current user */
.message-box-end {
  border-top-left-radius: 1rem;
  border-top-right-radius: 1rem;
  border-bottom-left-radius: 1rem;
  background-color: #0d6efd;
  color: white;
  word-wrap: break-word;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Profile images in chat */
.chat-profile-img {
  max-width: unset;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  background-color: #0a0e17;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Chat readonly notice */
.chat-readonly-notice {
  font-size: 0.875rem;
  color: #e2e2e2;
  background-color: #2c2c2c;
  border-color: #444444;
  border-radius: 0.25rem;
  padding: 0.5rem 1rem;
  margin-top: 0.5rem;
  text-align: center;
}

/* Disabled state for chat input */
#chatInput:disabled,
#sendChatBtn:disabled {
  cursor: not-allowed;
  opacity: 0.65;
}

/* Style for chat input when disabled */
#chatInput:disabled {
  background-color: #2b2b2b;
}

/* Add a subtle visual indicator that chat is read-only */
.chat-readonly #ChatMessages {
  opacity: 0.8;
}

/* Chat timestamp */
.message-time {
  font-size: 0.75rem;
  color: #6c757d;
  margin-top: 0.25rem;
}

/* Textarea styling */
#chatInput {
  min-height: 45px;
  max-height: 120px;
  resize: none;
  overflow-y: auto;
  background-color: #2b2b2b;
  color: #fff;
  border-color: #444;
}

/* Input group alignment for textarea */
.input-group {
  align-items: flex-end;
}

/* Focus state for textarea */
#chatInput:focus {
  background-color: #333;
  color: #fff;
  border-color: #0d6efd;
  box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

.chat-privacy-notice {
  background-color: rgba(0, 0, 0, 0.2);
  font-size: 0.8rem;
  text-align: center;
  padding: 8px 10px;
  margin-bottom: 15px;
  border-radius: 6px;
  backdrop-filter: blur(4px);
}