/* ECNChat Webchat W3 — original chat-pane appearance restoration */

/*
  This file loads after all other styles. It restores the original webchat
  transcript behavior while the website theme stylesheets are disabled.
*/

body.chatActive #log,
body.chatActive #chatMessages {
  color: #000000 !important;
  -webkit-text-fill-color: #000000 !important;
  background: #ffffff !important;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 13px;
}

body.chatActive #log .msg,
body.chatActive #chatMessages .msg {
  color: #000000;
  -webkit-text-fill-color: currentColor;
  opacity: 1;
  visibility: visible;
  text-shadow: none;
}

/* All public sender-name implementations used by recent repairs. */
body.chatActive #log :is(
  .ecnMessageSender,
  .ecnMessageSenderText,
  .ecnMessageSenderWrap,
  .sender,
  .senderName,
  .username,
  .messageUser
) {
  color: #000000 !important;
  -webkit-text-fill-color: #000000 !important;
  font-family: Arial, Helvetica, sans-serif !important;
  font-size: 13px !important;
  font-style: normal !important;
  font-weight: 400 !important;
  opacity: 1 !important;
  visibility: visible !important;
  text-shadow: none !important;
  filter: none !important;
  mix-blend-mode: normal !important;
}

/* SVG and canvas experiments remain visible if they are present. */
body.chatActive #log .ecnMessageSenderSVG,
body.chatActive #log .ecnMessageSenderCanvas {
  display: inline-block !important;
  vertical-align: middle !important;
  opacity: 1 !important;
  visibility: visible !important;
  filter: none !important;
  mix-blend-mode: normal !important;
}

body.chatActive #log .ecnMessageSenderSVG text {
  fill: #000000 !important;
  color: #000000 !important;
}

/* Topic remains black. */
body.chatActive #log .topicNotice,
body.chatActive #log .ecnTopicLabel,
body.chatActive #log .ecnTopicText {
  color: #000000 !important;
  -webkit-text-fill-color: #000000 !important;
  opacity: 1 !important;
  visibility: visible !important;
  text-shadow: none !important;
}

/* Preserve intended special line colors. */
body.chatActive #log .welcome {
  color: #008000 !important;
  -webkit-text-fill-color: #008000 !important;
  font-weight: 700;
}

body.chatActive #log .system,
body.chatActive #log .arrival,
body.chatActive #log .departure {
  color: #777777 !important;
  -webkit-text-fill-color: #777777 !important;
}

body.chatActive #log .motd {
  color: #000000 !important;
  -webkit-text-fill-color: #000000 !important;
}

/* Preserve the webchat's own full-screen sizing. */
body.chatActive #chat {
  position: fixed !important;
  inset: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  height: 100dvh !important;
  margin: 0 !important;
  z-index: 10020 !important;
}

body.chatActive #ecnUnifiedSiteShell {
  display: none !important;
}
