@charset "UTF-8";
@layer main {
  /* Top banner advertising chat to non-logged users */
  .chat-banner {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1001;
    display: none;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 10px 15px;
    background: linear-gradient(135deg, #003366, #001f3f);
    color: white;
    font-size: 0.9em;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  }
  .chat-banner.visible {
    display: flex;
  }
  .chat-banner span {
    display: flex;
    align-items: center;
    gap: 8px;
  }
  .chat-banner .chat-banner-cta {
    padding: 6px 16px;
    border: none;
    border-radius: 20px;
    background: white;
    color: #003366;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: transform 0.2s;
  }
  .chat-banner .chat-banner-cta:hover {
    transform: scale(1.05);
  }
  .chat-banner .chat-banner-dismiss {
    padding: 4px 8px;
    border: none;
    background: transparent;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    font-size: 1.1em;
  }
  .chat-banner .chat-banner-dismiss:hover {
    color: white;
  }
  @media (max-width: 500px) {
    .chat-banner {
      font-size: 0.8em;
      gap: 8px;
    }
  }
  /* Chat icon button placed in nav top-bar */
  .chat-toggle {
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: inherit;
    position: relative;
  }
  .chat-toggle i {
    font-size: 1.05em;
  }
  .chat-toggle .chat-badge {
    position: absolute;
    top: -6px;
    right: -10px;
    background: #dc3545;
    color: white;
    border-radius: 10px;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    font-size: 10px;
    font-weight: 700;
    display: none;
    align-items: center;
    justify-content: center;
  }
  .chat-toggle .chat-badge.visible {
    display: flex;
  }
  /* Modeless resizable chat dialog */
  .chat-dialog {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 720px;
    height: 480px;
    min-width: 360px;
    min-height: 280px;
    max-width: 95vw;
    max-height: 90vh;
    background: #fff;
    border: 1px solid #003366;
    border-radius: 8px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
    display: none;
    flex-direction: column;
    overflow: hidden;
    resize: both;
    z-index: 1100;
    font-family: var(--bs-font-sans-serif, sans-serif);
  }
  .chat-dialog.visible {
    display: flex;
  }
  .chat-header {
    display: flex;
    align-items: center;
    padding: 8px 12px;
    background: linear-gradient(135deg, #003366, #001f3f);
    color: #fff;
    cursor: move;
    user-select: none;
  }
  .chat-header .chat-title {
    flex: 1;
    font-weight: 600;
    font-size: 0.95em;
  }
  .chat-header .chat-title i {
    margin-right: 6px;
  }
  .chat-header .chat-status {
    font-size: 0.75em;
    opacity: 0.8;
    margin-right: 8px;
  }
  .chat-header .chat-status.connected::before {
    content: "● ";
    color: #2ecc71;
  }
  .chat-header .chat-status.disconnected::before {
    content: "● ";
    color: #e74c3c;
  }
  .chat-header .chat-status.connecting::before {
    content: "● ";
    color: #f1c40f;
  }
  .chat-header .chat-close {
    background: none;
    border: none;
    color: #fff;
    cursor: pointer;
    font-size: 1.1em;
    padding: 0 4px;
  }
  .chat-header .chat-close:hover {
    color: #ffcccc;
  }
  .chat-body {
    flex: 1;
    display: flex;
    overflow: hidden;
    min-height: 0;
  }
  .chat-channels {
    width: 160px;
    flex-shrink: 0;
    background: #f3f5f8;
    border-right: 1px solid #d8dce4;
    display: flex;
    flex-direction: column;
    min-height: 0;
  }
  .chat-channels .chat-channels-list {
    flex: 1;
    overflow-y: auto;
    padding: 8px 0;
  }
  .chat-channels .chat-username {
    border-top: 1px solid #d8dce4;
    padding: 8px 10px;
    background: #e7ebf2;
    font-size: 0.8em;
    color: #003366;
    display: flex;
    align-items: center;
    gap: 6px;
  }
  .chat-channels .chat-username .chat-username-label {
    font-size: 0.7em;
    color: #888;
    text-transform: uppercase;
  }
  .chat-channels .chat-username .chat-username-name {
    flex: 1;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .chat-channels .chat-username .chat-username-edit {
    background: none;
    border: none;
    cursor: pointer;
    color: #003366;
    padding: 2px 4px;
    border-radius: 3px;
    font-size: 0.95em;
  }
  .chat-channels .chat-username .chat-username-edit:hover {
    background: #d8dce4;
  }
  .chat-channels .chat-username input.chat-username-input {
    flex: 1;
    border: 1px solid #003366;
    border-radius: 3px;
    padding: 2px 6px;
    font-size: 1em;
    font-family: inherit;
    background: #fff;
    min-width: 0;
  }
  .chat-channels .chat-username input.chat-username-input:focus {
    outline: none;
  }
  .chat-channels .chat-channel {
    padding: 6px 14px;
    cursor: pointer;
    color: #444;
    font-size: 0.9em;
    border-left: 3px solid transparent;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }
  .chat-channels .chat-channel:hover {
    background: #e7ebf2;
  }
  .chat-channels .chat-channel.active {
    background: #e7ebf2;
    color: #003366;
    border-left-color: #003366;
    font-weight: 600;
  }
  .chat-channels .chat-channel .channel-unread {
    background: #dc3545;
    color: white;
    font-size: 10px;
    font-weight: 700;
    border-radius: 10px;
    padding: 1px 6px;
    display: none;
  }
  .chat-channels .chat-channel .channel-unread.visible {
    display: inline-block;
  }
  .chat-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    min-height: 0;
  }
  .chat-channel-header {
    padding: 8px 14px;
    border-bottom: 1px solid #e1e5ec;
    font-size: 0.85em;
    color: #666;
    background: #fafbfc;
  }
  .chat-channel-header .chat-channel-title {
    font-weight: 600;
    color: #003366;
    margin-right: 8px;
  }
  .chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 10px 14px;
    background: #fff;
  }
  .chat-messages .chat-load-older {
    text-align: center;
    padding: 6px;
    font-size: 0.8em;
    color: #888;
    cursor: pointer;
  }
  .chat-messages .chat-load-older:hover {
    color: #003366;
  }
  .chat-messages .chat-load-older.loading {
    cursor: wait;
  }
  .chat-messages .chat-msg {
    margin: 4px 0;
    padding: 2px 6px;
    border-radius: 4px;
    display: flex;
    gap: 8px;
    align-items: baseline;
    line-height: 1.35;
    font-size: 0.9em;
  }
  .chat-messages .chat-msg:hover .chat-msg-delete {
    visibility: visible;
  }
  .chat-messages .chat-msg.mentioned {
    background: #fff8d6;
    border-left: 3px solid #f1c40f;
  }
  .chat-messages .chat-msg .chat-mention {
    color: #003366;
    background: #dbe6f3;
    padding: 0 4px;
    border-radius: 3px;
    font-weight: 600;
  }
  .chat-messages .chat-msg .chat-msg-display {
    font-weight: 600;
    color: #003366;
    flex-shrink: 0;
  }
  .chat-messages .chat-msg .chat-msg-time {
    color: #999;
    font-size: 0.75em;
    flex-shrink: 0;
  }
  .chat-messages .chat-msg .chat-msg-content {
    flex: 1;
    white-space: pre-wrap;
    word-break: break-word;
    color: #222;
  }
  .chat-messages .chat-msg .chat-msg-delete {
    visibility: hidden;
    background: none;
    border: none;
    color: #dc3545;
    cursor: pointer;
    font-size: 0.85em;
    padding: 0 4px;
  }
  .chat-messages .chat-msg .chat-msg-delete:hover {
    color: #a71d2a;
  }
  .chat-messages .chat-day-sep {
    text-align: center;
    margin: 10px 0;
    font-size: 0.75em;
    color: #999;
  }
  .chat-messages .chat-day-sep::before, .chat-messages .chat-day-sep::after {
    content: "";
    display: inline-block;
    width: 25%;
    height: 1px;
    background: #e1e5ec;
    vertical-align: middle;
    margin: 0 8px;
  }
  .chat-input-area {
    border-top: 1px solid #e1e5ec;
    padding: 8px 10px;
    background: #fafbfc;
    display: flex;
    flex-direction: column;
    gap: 6px;
  }
  .chat-input-area .chat-emoji-bar {
    display: flex;
    gap: 4px;
  }
  .chat-input-area .chat-emoji-bar button {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.1em;
    padding: 2px 5px;
    border-radius: 4px;
  }
  .chat-input-area .chat-emoji-bar button:hover {
    background: #e7ebf2;
  }
  .chat-input-area .chat-input-row {
    display: flex;
    gap: 6px;
    align-items: flex-end;
  }
  .chat-input-area .chat-input-row textarea {
    flex: 1;
    resize: none;
    border: 1px solid #d8dce4;
    border-radius: 6px;
    padding: 6px 10px;
    font-size: 0.9em;
    font-family: inherit;
    max-height: 100px;
    line-height: 1.35;
  }
  .chat-input-area .chat-input-row textarea:focus {
    outline: none;
    border-color: #003366;
  }
  .chat-input-area .chat-input-row .chat-send {
    background: #003366;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 6px 14px;
    cursor: pointer;
    font-size: 0.9em;
  }
  .chat-input-area .chat-input-row .chat-send:hover {
    background: #001f3f;
  }
  .chat-input-area .chat-input-row .chat-send:disabled {
    background: #adb5bd;
    cursor: not-allowed;
  }
  .chat-guest-cta {
    padding: 12px;
    background: #f3f5f8;
    border-top: 1px solid #e1e5ec;
    text-align: center;
    font-size: 0.85em;
    color: #555;
  }
  .chat-guest-cta a {
    display: inline-block;
    margin-top: 6px;
    padding: 6px 14px;
    background: #003366;
    color: #fff;
    border-radius: 20px;
    text-decoration: none;
    font-weight: 600;
  }
  .chat-guest-cta a:hover {
    background: #001f3f;
  }
  /* Mobile: full-screen dialog */
  @media (max-width: 700px) {
    .chat-dialog {
      bottom: 0;
      right: 0;
      left: 0;
      top: 0;
      width: auto;
      height: auto;
      max-width: none;
      max-height: none;
      border-radius: 0;
      resize: none;
    }
    .chat-channels {
      width: 120px;
    }
  }
  /* Contact-page chat advert */
  .contact-chat-advert {
    margin-top: 30px;
    padding: 18px 20px;
    background: linear-gradient(135deg, #003366, #001f3f);
    color: #fff;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 14px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  }
  .contact-chat-advert i {
    font-size: 1.6em;
  }
  .contact-chat-advert .label {
    flex: 1;
    line-height: 1.4;
  }
  .contact-chat-advert button {
    background: #fff;
    color: #003366;
    border: none;
    border-radius: 20px;
    padding: 8px 18px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s;
  }
  .contact-chat-advert button:hover {
    transform: scale(1.05);
  }
}

/*# sourceMappingURL=chat.css.map */
