/* Styles for enhanced comments with media attachments */

/* Comment form container */
.comment-form {
  display: flex;
  align-items: flex-start;
  margin-top: 10px;
  padding: 10px;
  border-top: 1px solid var(--border-color);
}

/* Comment input container */
.comment-input-container {
  flex-grow: 1;
  margin-left: 10px;
  display: flex;
  flex-direction: column;
}

/* Comment input field */
.comment-input {
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 8px 15px;
  width: 100%;
  background-color: var(--input-bg);
  color: var(--text-primary);
}

/* Comment actions */
.comment-actions {
  display: flex;
  margin-top: 5px;
  justify-content: flex-end;
}

/* Comment action buttons */
.comment-action-btn {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 14px;
  cursor: pointer;
  margin-right: 8px;
  padding: 5px;
  border-radius: 50%;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.comment-action-btn:hover {
  background-color: var(--hover-bg);
  color: var(--primary-color);
}

/* Send comment button */
.send-comment {
  background-color: var(--primary-color);
  color: white;
  border: none;
  border-radius: 50%;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 0.2s;
}

.send-comment:hover {
  background-color: var(--primary-color-dark);
}

/* Comment media preview */
.media-preview {
  margin-top: 5px;
  display: none;
  position: relative;
  border-radius: 10px;
  overflow: hidden;
}

.media-preview img,
.media-preview video {
  max-width: 100%;
  max-height: 150px;
  border-radius: 8px;
}

.media-preview .remove-media-btn {
  position: absolute;
  top: 5px;
  right: 5px;
  background-color: rgba(0, 0, 0, 0.6);
  color: white;
  border: none;
  border-radius: 50%;
  width: 25px;
  height: 25px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 12px;
  z-index: 10;
}

/* Comment reactions */
.comment-reactions {
  display: flex;
  margin-top: 5px;
  gap: 5px;
}

.comment-reaction-btn {
  background: none;
  border: none;
  font-size: 12px;
  padding: 3px;
  cursor: pointer;
  border-radius: 4px;
  color: var(--text-secondary);
}

.comment-reaction-btn:hover {
  background-color: var(--hover-bg);
}

.comment-reaction-btn.active {
  color: var(--primary-color);
}

/* Comment display styles */
.comment {
  display: flex;
  padding: 10px;
  border-bottom: 1px solid var(--border-color);
}

.comment-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  margin-right: 10px;
}

.comment-content {
  flex-grow: 1;
  background-color: var(--surface);
  border-radius: 12px;
  padding: 8px 12px;
}

.comment-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 3px;
  width: 100%;
}

.comment-user-info {
  display: flex;
  align-items: center;
  gap: 8px;
}

.comment-username {
  font-weight: bold;
  color: var(--text-primary);
  text-decoration: none;
}

.comment-time {
  font-size: 12px;
  color: var(--text-secondary);
  white-space: nowrap;
}

.comment-text {
  color: var(--text-primary);
  word-break: break-word;
}

.comment-media {
  margin-top: 5px;
  border-radius: 8px;
  overflow: hidden;
}

.comment-media img,
.comment-media video {
  max-width: 100%;
  max-height: 150px;
  border-radius: 8px;
}

/* Comment reactions display */
.comment-reactions-display {
  display: flex;
  align-items: center;
  margin-top: 5px;
  font-size: 12px;
  color: var(--text-secondary);
}

.comment-reaction-icons {
  display: flex;
  margin-right: 5px;
}

.comment-reaction-icon {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--primary-color);
  color: white;
  margin-left: -5px;
  box-shadow: 0 0 0 2px white;
}

.comment-reaction-icon:first-child {
  margin-left: 0;
}

.comment-reactions-count {
  font-size: 11px;
}
