.vsd-2601 .vsd-element.vsd-element-c399c61{--display:flex;--flex-direction:column;--container-widget-width:100%;--container-widget-height:initial;--container-widget-flex-grow:0;--container-widget-align-self:initial;--flex-wrap-mobile:wrap;}/* Start custom CSS for html, class: .vsd-element-04b3ac2 */*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Inter', 'Sofia Sans', sans-serif;
  background: #eef1f5;
  color: #222;
  -webkit-font-smoothing: antialiased;
  height: 100vh;
  overflow: auto; /* fix here */
}


.chat-container {
  display: flex;
  height: 90vh;
  width: 100%;
  max-width: 1400px;
  margin: 5vh auto;
  border-radius: 20px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.45);
  backdrop-filter: blur(18px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
  position: relative;
  z-index: 1;
}

/* SIDEBAR */
.chat-sidebar {
  width: 260px;
  background: rgba(250, 250, 250, 0.6);
  border-right: 1px solid rgba(200, 200, 200, 0.4);
  display: flex;
  flex-direction: column;
  position: relative; 
}

.chat-sidebar-header {
  padding: 1.2em;
  font-weight: 700;
  font-size: 1.2em;
  color: #333;
  border-bottom: 1px solid rgba(180, 180, 180, 0.3);
  background: rgba(255, 255, 255, 0.35);
}

.chat-user-list {
  flex: 1;
  overflow-y: auto;
  margin: 0;
  padding: 0;
  list-style: none;
  scrollbar-width: thin;
  scrollbar-color: #bbb transparent;
}

.chat-user-item {
  padding: 0.8em 1em;
  display: flex;
  align-items: center;
  gap: 0.8em;
  cursor: pointer;
  transition: background 0.15s ease;
  border-bottom: 1px solid rgba(200, 200, 200, 0.15);
}

.chat-user-item:hover {
  background: rgba(200, 200, 200, 0.2);
}

/* MAIN */
.chat-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: transparent;
}

.chat-header {
  padding: 1em 1.4em;
  background: rgba(255, 255, 255, 0.4);
  border-bottom: 1px solid rgba(220, 220, 220, 0.4);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
  backdrop-filter: blur(10px);
}

.chat-title {
  font-size: 1.3em;
  margin: 0;
}

.chat-online-count {
  font-size: 0.9em;
  color: #666;
}

/* MESSAGES */
.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 1.4em;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.35), rgba(240, 240, 240, 0.2));
  scroll-behavior: smooth;
}

.chat-message {
  background: rgba(255, 255, 255, 0.6);
  border-radius: 12px;
  padding: 0.8em 1em;
  margin-bottom: 1em;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
  transition: transform 0.15s ease;
}

.chat-message:hover {
  transform: scale(1.015);
}

.chat-message strong {
  color: #222;
  display: block;
  margin-bottom: 0.3em;
}

/* INPUT AREA */
.chat-input-area {
  display: flex;
  gap: 0.6em;
  padding: 1em;
  border-top: 1px solid rgba(200, 200, 200, 0.3);
  background: rgba(255, 255, 255, 0.55);
  backdrop-filter: blur(12px);
}

.chat-input {
  flex: 1;
  padding: 0.7em 1em;
  border: 1px solid #ccc;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.85);
  font-size: 1em;
  outline: none;
  transition: border 0.2s ease;
}

.chat-input:focus {
  border-color: #aaa;
}

/* BUTTONS */
.chat-emoji-btn,
.chat-attach-btn,
.chat-send-btn {
  border: none;
  padding: 0.65em 0.9em;
  font-size: 1.1em;
  border-radius: 10px;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.1s ease;
  background: rgba(245, 245, 245, 0.9);
  backdrop-filter: blur(8px);
}

.chat-emoji-btn:hover,
.chat-attach-btn:hover {
  background: rgba(230, 230, 230, 0.9);
  transform: scale(1.05);
}

.chat-send-btn {
  background: linear-gradient(to right, #4b83fc, #709dff);
  color: #fff;
  font-weight: 600;
}

.chat-send-btn:hover {
  background: linear-gradient(to right, #3c75ee, #5b8dff);
}

/* SCROLLBAR */
.chat-user-list::-webkit-scrollbar,
.chat-messages::-webkit-scrollbar {
  width: 8px;
}
.chat-user-list::-webkit-scrollbar-thumb,
.chat-messages::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.1);
  border-radius: 4px;
}

/* ЕКСТРИ КЪМ ЧАТА */

/* USER AVATAR + STATUS */
.chat-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-size: cover;
  background-position: center;
  flex-shrink: 0;
  border: 2px solid #ddd;
  box-shadow: 0 0 0 2px #fff;
}

.chat-username {
  flex-grow: 1;
  font-weight: 500;
  color: #222;
}

/* ONLINE/OFFLINE STATUS */
.chat-user-item.online::after,
.chat-user-item.offline::after {
  content: '';
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-left: auto;
  box-shadow: 0 0 0 1px #fff;
}

.chat-user-item.online::after {
  background: #2ecc71;
}

.chat-user-item.offline::after {
  background: #ccc;
}

/* SELF MESSAGE STYLE */
/* Плавен fade от зелено към фин цвят */
.chat-message.self {
  align-self: flex-end;
  background: #d4fdd7;
  animation: fadeSelfBg 1.2s forwards;
  border-radius: 16px 16px 4px 16px;
  padding: 0.8em 1em;
  box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}

@keyframes fadeSelfBg {
  0% {
    background: #d4fdd7;
  }
  100% {
    background: #eef6f0;
  }
}


/* AUTHOR, TEXT, TIMESTAMP STRUCTURE */
.chat-message .chat-author {
  font-weight: 600;
  color: #2b2b2b;
  margin-bottom: 0.3em;
}

.chat-message .chat-text {
  white-space: pre-wrap;
  line-height: 1.5;
  color: #333;
}

.chat-message .chat-timestamp {
  margin-top: 0.5em;
  font-size: 0.75em;
  color: #888;
  text-align: right;
}

/* INPUT FIELD VALIDATION FEEDBACK */
.chat-input.invalid {
  border-color: #e74c3c;
  box-shadow: 0 0 0 2px rgba(231, 76, 60, 0.2);
}

/* FOCUS STYLE FOR ACCESSIBILITY */
.chat-user-item:focus-visible,
.chat-emoji-btn:focus-visible,
.chat-attach-btn:focus-visible,
.chat-send-btn:focus-visible,
.chat-input:focus-visible {
  outline: 2px solid #4b83fc;
  outline-offset: 2px;
}

/* RESPONSIVE: BURGER + HIDE SIDEBAR ON SMALL */
@media (max-width: 640px) {
  .chat-container {
    flex-directi/* End custom CSS */
/* Start custom CSS for html, class: .vsd-element-3b964db */.user-popup {
  position: absolute;
  z-index: 9999;
  min-width: 240px;
  max-width: 300px;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(14px);
  border-radius: 16px;
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.15);
  padding: 1em;
  transition: opacity 0.2s ease, transform 0.2s ease;
  opacity: 0;
  pointer-events: none;
}

.user-popup.show {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.user-popup-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.8em;
}

.popup-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background-size: cover;
  background-position: center;
  box-shadow: 0 0 0 2px #fff;
}

.popup-info {
  text-align: center;
}

.popup-name {
  font-size: 1.1em;
  font-weight: 600;
  color: #222;
}

.popup-status {
  font-size: 0.85em;
  margin-top: 0.2em;
  color: #666;
}
.popup-status.online::before {
  content: '●';
  color: #2ecc71;
  margin-right: 0.4em;
}
.popup-status.offline::before {
  content: '●';
  color: #ccc;
  margin-right: 0.4em;
}

.popup-actions {
  display: flex;
  flex-direction: column;
  gap: 0.5em;
  width: 100%;
  margin-top: 0.6em;
}

.popup-profile-link,
.popup-message-btn {
  text-align: center;
  padding: 0.6em 1em;
  border: none;
  border-radius: 10px;
  background: #f5f7fa;
  color: #333;
  text-decoration: none;
  font-weight: 500;
  transition: background 0.2s ease;
  cursor: pointer;
}

.popup-profile-link:hover,
.popup-message-btn:hover {
  background: #e0e5ec;
}/* End custom CSS */