#support-chat-root {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 1050;
  font-family: 'Inter', 'Segoe UI', sans-serif;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
  pointer-events: none;
}

#support-chat-toggle {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: none;
  background: linear-gradient(135deg, #212529, #000000);
  color: #fff;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

#support-chat-window {
  width: 320px;
  max-width: calc(100vw - 48px);
  background: #ffffff;
  border-radius: 20px;
  box-shadow: 0 18px 48px rgba(15, 15, 15, 0.35);
  overflow: hidden;
  transform: translateY(20px);
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
}

#support-chat-window.show {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

#support-chat-toggle {
  pointer-events: auto;
}

@media (max-width: 576px) {
  #support-chat-toggle {
    width: 48px;
    height: 48px;
    margin-bottom: 15px;
  }

  #support-chat-toggle i {
    font-size: 1.25rem;
  }
}

.support-chat__header {
  padding: 16px 20px;
  background: linear-gradient(135deg, #111, #2b2b2b);
  color: #fff;
}

.support-chat__messages {
  padding: 16px;
  background: #f8f9fa;
  height: 240px;
  overflow-y: auto;
}

.support-chat__message {
  margin-bottom: 12px;
  display: flex;
  flex-direction: column;
  max-width: 85%;
}

.support-chat__message--user {
  margin-left: auto;
  align-items: flex-end;
}

.support-chat__message--staff {
  margin-right: auto;
  align-items: flex-start;
}

.support-chat__bubble {
  padding: 10px 14px;
  border-radius: 14px;
  background: #0d6efd;
  color: #fff;
  white-space: pre-wrap;
  word-break: break-word;
  box-shadow: 0 6px 12px rgba(13, 110, 253, 0.25);
}

.support-chat__text {
  margin-bottom: 0;
}

.support-chat__attachment {
  margin-top: 8px;
  border-radius: 12px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.1);
}

.support-chat__attachment img {
  max-width: 100%;
  height: auto;
  display: block;
}

.support-chat__message--staff .support-chat__bubble {
  background: #e9ecef;
  color: #212529;
  box-shadow: none;
}

.support-chat__meta {
  font-size: 11px;
  color: #6c757d;
  margin-top: 4px;
}

.support-chat__form {
  padding: 16px;
  border-top: 1px solid #e9ecef;
  background: #fff;
}

.support-chat__form textarea {
  resize: none;
}

.support-chat__input-row {
  display: flex;
  align-items: stretch;
  gap: 8px;
}

.support-chat__textarea {
  flex: 1 1 auto;
  min-height: 60px;
}

.support-chat__attach-btn {
  flex: 0 0 42px;
  width: 42px;
  border: none;
  border-radius: 12px;
  background: #f1f3f5;
  color: #495057;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.support-chat__attach-btn:hover,
.support-chat__attach-btn:focus {
  background: #e9ecef;
  color: #212529;
  transform: translateY(-1px);
}

.support-chat__attach-btn:active {
  transform: translateY(0);
}

.support-chat__attach-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.support-chat__error {
  color: #dc3545;
  font-size: 13px;
  margin-bottom: 8px;
}

@media (max-width: 576px) {
  #support-chat-root {
    right: 16px;
    bottom: 16px;
  }

  #support-chat-window {
    width: calc(100vw - 32px);
  }
}