/* Community Live Chat — global member lounge (faq.php?tab=chat) */

.lc-room,
.lc-room * {
  box-sizing: border-box;
}

html.live-chat-root,
html.live-chat-root body.live-chat-page {
  height: 100%;
  max-height: 100%;
  overflow: hidden;
}

.live-chat-page {
  height: 100dvh;
  max-height: 100dvh;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #000;
}

.live-chat-page .lc-page-shell.container {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  overflow: hidden;
  width: 100%;
  max-width: 100% !important;
  margin-top: 0;
  padding: 10px 14px 12px;
  background: #000;
}

.live-chat-page #supportTabsContent,
.live-chat-page #chat-pane,
.live-chat-page .lc-layout {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  overflow: hidden;
}

.live-chat-page .lc-layout {
  width: 100%;
}

.lc-room {
  --lc-main: #000;
  --lc-parent: #101010;
  --lc-border: #222;
  --lc-gold: #ffd700;
  --lc-gold-soft: rgba(255, 215, 0, 0.12);
  --lc-text: #e5e7eb;
  --lc-muted: #9aa3af;
  --lc-bubble-theirs: #141414;
  --lc-bubble-mine: rgba(255, 215, 0, 0.1);
  --lc-bubble-mine-border: rgba(255, 215, 0, 0.28);
  position: relative;
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  max-height: 100%;
  background: var(--lc-parent);
  border: 1px solid var(--lc-border);
  border-radius: 14px;
  overflow: hidden;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

.lc-room-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255, 215, 0, 0.12);
  background: var(--lc-parent);
  flex-shrink: 0;
}

.lc-room-head-main {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  min-width: 0;
}

.lc-room-title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.lc-room-title i {
  color: var(--lc-gold);
}

.lc-room-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.22);
  color: #86efac;
  font-size: 0.68rem;
  font-weight: 600;
}

.lc-room-badge.is-muted {
  background: rgba(148, 163, 184, 0.1);
  border-color: rgba(148, 163, 184, 0.22);
  color: #94a3b8;
}

.lc-room-badge i {
  font-size: 0.55rem;
}

.lc-mod-btn {
  width: 36px;
  height: 36px;
  border: 1px solid var(--lc-border);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--lc-muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.lc-mod-btn:hover {
  background: var(--lc-gold-soft);
  border-color: rgba(255, 215, 0, 0.35);
  color: var(--lc-gold);
}

.lc-messages-wrap {
  position: relative;
  flex: 1;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

#chatBox.lc-messages {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 16px 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: var(--lc-main);
  color: var(--lc-text);
}

.lc-jump-latest {
  position: absolute;
  left: 50%;
  bottom: 12px;
  z-index: 4;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid rgba(255, 215, 0, 0.35);
  background: rgba(12, 12, 14, 0.94);
  color: var(--lc-gold);
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.45);
  transform: translateX(-50%);
  transition: opacity 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.lc-jump-latest:hover {
  border-color: rgba(255, 215, 0, 0.55);
  background: rgba(18, 18, 20, 0.98);
}

.lc-jump-latest.is-hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateX(-50%) translateY(10px);
}

.lc-jump-latest i {
  font-size: 0.95rem;
  line-height: 1;
}

.lc-jump-latest-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--lc-gold);
  color: #111;
  font-size: 0.68rem;
  font-weight: 700;
}

.lc-jump-latest-count[hidden] {
  display: none !important;
}

.lc-date-separator,
.chat-date-separator {
  display: flex;
  justify-content: center;
  width: 100%;
  margin: 6px 0 2px;
}

.lc-date-separator span,
.chat-date-separator span {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.06);
  color: var(--lc-muted);
  font-size: 0.72rem;
  font-weight: 500;
  user-select: none;
}

.lc-msg-row {
  display: flex;
  flex-direction: column;
  width: fit-content;
  max-width: min(560px, 85%);
}

.lc-msg-row.is-theirs {
  align-self: flex-start;
  align-items: flex-start;
}

.lc-msg-row.is-mine {
  align-self: flex-end;
  align-items: flex-end;
}

.lc-msg-body {
  display: flex;
  align-items: flex-end;
  gap: 8px;
}

.lc-msg-row.is-mine .lc-msg-body {
  flex-direction: row-reverse;
}

.lc-msg-content {
  display: flex;
  flex-direction: column;
  min-width: 0;
  max-width: min(520px, calc(100vw - 120px));
}

.lc-msg-row.is-mine .lc-msg-content {
  align-items: flex-end;
}

.lc-room img.lc-msg-avatar,
.lc-msg-avatar {
  display: block;
  width: 32px !important;
  height: 32px !important;
  min-width: 32px;
  max-width: 32px;
  min-height: 32px;
  max-height: 32px;
  border-radius: 50%;
  object-fit: cover;
  flex: 0 0 32px;
  flex-shrink: 0;
  background: #222;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.lc-msg-row.is-mine .lc-msg-avatar {
  border-color: rgba(255, 215, 0, 0.35);
}

.lc-bubble-head {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 4px;
}

.lc-msg-sender {
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.2;
}

.lc-msg-row.is-theirs .lc-msg-sender {
  color: #111;
}

.lc-msg-row.is-mine .lc-msg-sender {
  color: #111;
}

.lc-msg-time {
  font-size: 0.72rem;
  color: #6b7280;
  margin-top: 4px;
  padding: 0 4px;
}

.chat-bubble.lc-bubble {
  position: relative;
  width: fit-content;
  max-width: min(520px, calc(100vw - 120px));
  margin: 0;
  padding: 10px 14px;
  border-radius: 16px;
  font-size: 0.9rem;
  line-height: 1.45;
  word-wrap: break-word;
  text-align: left;
  cursor: pointer;
  display: block;
  box-shadow: none;
  transition: box-shadow 0.2s ease;
}

.lc-msg-row.is-theirs .chat-bubble.lc-bubble {
  background: #fff;
  color: #111;
  border: none;
  border-bottom-left-radius: 6px;
}

.lc-msg-row.is-mine .chat-bubble.lc-bubble {
  background: var(--lc-gold);
  color: #111;
  border: none;
  border-bottom-right-radius: 6px;
}

.chat-bubble.lc-bubble.deleted {
  font-style: italic;
  color: var(--lc-muted);
  background: rgba(255, 255, 255, 0.04);
  border-style: dashed;
}

.chat-bubble.lc-bubble.is-hidden-mod {
  opacity: 0.55;
  outline: 1px dashed #64748b;
}

.chat-bubble.lc-bubble.highlight-target {
  box-shadow: 0 0 0 2px rgba(255, 215, 0, 0.65);
}

.chat-bubble.lc-bubble::before,
.chat-bubble.lc-bubble::after {
  display: none;
}

.chat-reply-preview {
  display: block;
  margin: -2px -2px 8px;
  padding: 8px 10px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.08);
  cursor: pointer;
  user-select: none;
}

.lc-msg-row.is-mine .chat-reply-preview {
  background: rgba(0, 0, 0, 0.08);
}

.chat-reply-preview-name {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  margin-bottom: 2px;
  color: #92700a;
}

.lc-msg-row.is-mine .chat-reply-preview-name {
  color: #111;
}

.chat-reply-preview-text {
  display: block;
  font-size: 0.78rem;
  line-height: 1.35;
  color: #4b5563;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lc-msg-row.is-mine .chat-reply-preview-text {
  color: #374151;
}

.chat-message {
  white-space: pre-line;
  word-break: break-word;
  text-align: left;
  margin: 0;
  padding: 0;
}

.lc-bubble-img {
  display: block;
  max-width: min(280px, 100%);
  max-height: 220px;
  width: auto;
  height: auto;
  margin-top: 2px;
  border-radius: 10px;
  object-fit: cover;
}

.lc-bubble-file {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.18);
  color: inherit;
  text-decoration: none;
  font-size: 0.84rem;
  font-weight: 600;
  word-break: break-all;
}

.lc-msg-row.is-mine .lc-bubble-file {
  background: rgba(0, 0, 0, 0.08);
  color: #111;
}

.chat-bubble.lc-bubble .chat-message + .lc-bubble-img,
.chat-bubble.lc-bubble .lc-bubble-img + .chat-message,
.chat-bubble.lc-bubble .lc-bubble-file + .chat-message,
.chat-bubble.lc-bubble .chat-message + .lc-bubble-file {
  margin-top: 8px;
}

.hidden-badge {
  color: #f87171;
  font-size: 0.72rem;
  font-weight: 600;
}

.mod-on .mod-toggle {
  display: inline-flex !important;
}

.mod-toggle {
  display: none;
  position: absolute;
  bottom: -18px;
  right: 0;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.35);
  font-size: 0.68rem;
  font-weight: 600;
  text-decoration: none;
  color: #fca5a5 !important;
  z-index: 2;
}


.lc-composer-wrap {
  flex-shrink: 0;
  width: 100%;
  align-self: stretch;
  box-sizing: border-box;
  padding: 14px 16px 16px;
  border-top: 1px solid rgba(255, 215, 0, 0.12);
  background: var(--lc-parent);
}

#replyPreview.lc-reply-bar {
  display: none;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  background: var(--lc-gold-soft);
  border: 1px solid rgba(255, 215, 0, 0.22);
  color: var(--lc-text);
  font-size: 0.82rem;
}

#replyPreview.lc-reply-bar strong {
  color: var(--lc-gold);
}

#replyPreview #cancelReply {
  margin-left: auto;
  color: #94a3b8;
  text-decoration: none;
}

.lc-access-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 215, 0, 0.18);
}

.lc-access-banner-text {
  margin: 0;
  font-size: 0.8125rem;
  color: #cbd5e1;
  line-height: 1.45;
}

.lc-access-banner-text strong {
  color: var(--lc-gold);
}

.lc-access-banner .lc-btn {
  flex-shrink: 0;
  white-space: nowrap;
}

.lc-access-banner.is-trial {
  border-color: rgba(248, 113, 113, 0.25);
  background: rgba(248, 113, 113, 0.08);
}

.lc-composer-wrap > form,
.lc-composer-form,
#chatForm.lc-composer-form,
#chatForm.lc-composer {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin: 0;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  align-self: stretch;
}

.lc-composer-row {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
}

.lc-composer-attach {
  width: 36px;
  height: 36px;
  border: none;
  background: transparent;
  color: #9ca3af;
  font-size: 1.15rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  border-radius: 8px;
  appearance: none;
  -webkit-appearance: none;
  box-shadow: none;
  padding: 0;
  line-height: 1;
  transition: color 0.2s ease, background 0.2s ease, transform 0.15s ease;
}

.lc-composer-attach:hover:not(:disabled) {
  color: #fff;
  background: rgba(255, 255, 255, 0.06);
  transform: rotate(-12deg) scale(1.06);
}

.lc-composer-attach:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.lc-composer-file {
  display: none;
}

.lc-attach-preview {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0;
  margin: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 215, 0, 0.14);
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  pointer-events: none;
  transition: max-height 0.2s ease, opacity 0.2s ease, margin 0.2s ease, padding 0.2s ease;
}

.lc-attach-preview.is-visible {
  max-height: 72px;
  opacity: 1;
  margin-bottom: 10px;
  padding: 8px 10px;
  pointer-events: auto;
}

.lc-attach-preview-thumb {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  overflow: hidden;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 215, 0, 0.08);
  color: #ffd700;
  font-size: 1.1rem;
}

.lc-attach-preview-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.lc-attach-preview-meta {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.lc-attach-preview-name {
  font-size: 0.82rem;
  color: #f3f4f6;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lc-attach-preview-type {
  font-size: 0.74rem;
  color: #9ca3af;
}

.lc-attach-preview-clear {
  width: 24px;
  height: 24px;
  border: none;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.08);
  color: #d1d5db;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.lc-attach-preview-clear:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.14);
}

.lc-composer-input,
#chatInput.lc-composer-input {
  flex: 1;
  min-width: 0;
  height: 42px;
  padding: 0 14px;
  border-radius: 12px;
  border: 1px solid #222;
  background: #000;
  color: #fff;
  font-size: 0.875rem;
  font-family: inherit;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.lc-composer-input:focus,
#chatInput.lc-composer-input:focus {
  outline: none;
  border-color: rgba(255, 215, 0, 0.45);
  box-shadow: 0 0 0 3px rgba(255, 215, 0, 0.08);
}

.lc-composer-input:disabled,
#chatInput.lc-composer-input:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.lc-send-btn,
#sendBtn.lc-send-btn {
  height: 42px;
  padding: 0 18px;
  border: none;
  border-radius: 12px;
  background: var(--lc-gold);
  color: #0d0e14;
  font-size: 0.8125rem;
  font-weight: 700;
  font-family: inherit;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.15s ease;
}

.lc-send-btn:hover:not(:disabled),
#sendBtn.lc-send-btn:hover:not(:disabled) {
  background: #f5c400;
}

.lc-send-btn:disabled,
#sendBtn.lc-send-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.lc-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 10px;
  background: var(--lc-gold);
  color: #0d0e14;
  font-size: 0.8125rem;
  font-weight: 700;
  text-decoration: none;
  border: none;
  cursor: pointer;
}

.lc-btn:hover {
  background: #f5c400;
  color: #0d0e14;
}

.lc-btn-ghost {
  background: transparent;
  border: 1px solid var(--lc-border);
  color: var(--lc-text);
}

.lc-btn-ghost:hover {
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
}

.chat-empty.lc-empty {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 200px;
  color: var(--lc-muted);
  font-size: 0.92rem;
  text-align: center;
  font-style: normal;
}

.lc-empty i {
  font-size: 1.75rem;
  color: rgba(255, 215, 0, 0.35);
}

.live-chat-page.custom-container,
.live-chat-page .custom-container {
  max-width: none;
}

.custom-container {
  max-width: 1400px;
  margin: 0 auto;
}

@media (max-width: 991px) {
  .live-chat-page .lc-page-shell.container {
    padding: 8px 10px 10px;
  }
}

@media (max-width: 768px) {
  .lc-room {
    border-radius: 10px;
  }

  .lc-msg-row {
    max-width: min(520px, 92%);
  }

  .chat-bubble.lc-bubble {
    max-width: calc(100vw - 118px);
  }

  .lc-room-head-main {
    gap: 6px;
  }

  .lc-room-title {
    font-size: 0.95rem;
  }

  .lc-access-banner {
    flex-direction: column;
    align-items: stretch;
  }

  .lc-access-banner .lc-btn {
    width: 100%;
    justify-content: center;
  }
}

@media (min-width: 1600px) {
  .custom-container {
    max-width: 1500px;
  }
}
