/* 完全平铺式布局 */
.sammi-zibll-comment-flat-comments {
  max-width: 680px;
  margin: 2rem auto;
  background: var(--body-bg-color);
  border-radius: 10px;
  padding: 1rem;
}

body.dark-theme .sammi-zibll-comment-flat-comments {
  background: #222;
  color: #e0e0e0;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.sammi-zibll-comment-comment-item {
  border-bottom: 1px solid #eee;
  padding: 1rem 0;
}

body.dark-theme .sammi-zibll-comment-comment-item {
  border-bottom: 1px solid #444;
}

.sammi-zibll-comment-comment-item:last-child {
  border-bottom: none;
}

/* 元信息布局 */
.sammi-zibll-comment-comment-meta {
  margin-bottom: 0;
  display: inline;
}

.sammi-zibll-comment-meta-info {
  line-height: 1.4;
  display: inline;
}

body.dark-theme .sammi-zibll-comment-meta-info {
  color: #e0e0e0;
}

.sammi-zibll-comment-comment-content {
  display: inline;
  white-space: pre-line;
}

.sammi-zibll-comment-comment-content p {
  display: inline;
  margin: 0;
}

body.dark-theme .sammi-zibll-comment-comment-content p {
  color: #e0e0e0;
}

.sammi-zibll-comment-meta-info .sammi-zibll-comment-author {
  display: inline-block;
  font-weight: 600;
}

body.dark-theme .sammi-zibll-comment-meta-info .sammi-zibll-comment-author {
  color: #e0e0e0;
}

.sammi-zibll-comment-meta-info::after {
  content: '：';
}

/* 回复上下文紧凑显示 */
.sammi-zibll-comment-reply-context {
  display: inline;
  color: #666;
  font-size: 1em;
}

body.dark-theme .sammi-zibll-comment-reply-context {
  color: #aaa;
}

.sammi-zibll-comment-reply-context a {
  color: #40a1ff;
  text-decoration: none;
}

body.dark-theme .sammi-zibll-comment-reply-context a {
  color: #5eb4ff;
}

.sammi-zibll-comment-reply-context a:hover {
  text-decoration: underline;
}

/* 操作按钮 */
.sammi-zibll-comment-comment-actions {
  margin-top: 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.sammi-zibll-comment-action-btns {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.sammi-zibll-comment-reply-btn,
.sammi-zibll-comment-delete-btn {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  font-size: 0.9em;
}

.sammi-zibll-comment-reply-btn {
  color: #40a1ff;
}

body.dark-theme .sammi-zibll-comment-reply-btn {
  color: #5eb4ff;
}

.sammi-zibll-comment-delete-btn {
  color: #ff4040;
}

body.dark-theme .sammi-zibll-comment-delete-btn {
  color: #ff6060;
}

.sammi-zibll-comment-reply-btn:hover,
.sammi-zibll-comment-delete-btn:hover {
  text-decoration: underline;
}

.sammi-zibll-comment-time {
  font-size: 0.9em;
  color: #666;
}

body.dark-theme .sammi-zibll-comment-time {
  color: #aaa;
}

/* 查看更多按钮 */
.sammi-zibll-comment-view-more {
  text-align: center;
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid #eee;
}

body.dark-theme .sammi-zibll-comment-view-more {
  border-top: 1px solid #444;
}

.sammi-zibll-comment-view-more-link {
  display: inline-block;
  padding: 0.5rem 1.5rem;
  background-color: #f5f6f7;
  color: #666;
  border-radius: 20px;
  text-decoration: none;
  transition: all 0.3s ease;
}

body.dark-theme .sammi-zibll-comment-view-more-link {
  background-color: #333;
  color: #ccc;
}

.sammi-zibll-comment-view-more-link:hover {
  background-color: #e9ecef;
  color: #40a1ff;
  text-decoration: none;
}

body.dark-theme .sammi-zibll-comment-view-more-link:hover {
  background-color: #444;
  color: #5eb4ff;
}

/* 评论表单样式 */
.sammi-zibll-comment-form {
  display: none; /* 默认隐藏 */
  padding: 1rem;
}

.sammi-zibll-comment-form.active {
  display: block; /* 显示时的状态 */
}

.sammi-zibll-comment-form textarea {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid #e0e0e0;
  border-radius: 6px;
  margin-bottom: 10px;
  resize: none;
  transition: all 0.3s ease;
  font-size: 14px;
  line-height: 1.5;
  overflow-y: hidden;
}

body.dark-theme .sammi-zibll-comment-form textarea {
  background-color: #2a2a2a;
  border-color: #444;
  color: #e0e0e0;
}

.sammi-zibll-comment-form textarea:focus {
  border-color: var(--focus-color);
  box-shadow: 0 0 0 2px var(--focus-shadow-color);
  outline: none;
}

body.dark-theme .sammi-zibll-comment-form textarea:focus {
  border-color: #5eb4ff;
  box-shadow: 0 0 0 2px rgba(94, 180, 255, 0.3);
}

.sammi-zibll-comment-form-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

body.dark-theme .sammi-zibll-comment-form-footer {
  color: #e0e0e0;
}

.sammi-zibll-comment-tools {
  display: flex;
  gap: 10px;
}

body.dark-theme .sammi-zibll-comment-tools {
  color: #e0e0e0;
}

/* 暗色模式按钮 */
.sammi-zibll-comment-dark-mode-toggle {
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-left: auto;
  padding: 5px;
  border-radius: 50%;
  background: transparent;
  transition: all 0.3s ease;
}

.sammi-zibll-comment-dark-mode-toggle:hover {
  background: rgba(0, 0, 0, 0.1);
}

body.dark-theme .sammi-zibll-comment-dark-mode-toggle:hover {
  background: rgba(255, 255, 255, 0.1);
}

.sammi-zibll-comment-dark-mode-toggle svg {
  width: 20px;
  height: 20px;
  fill: #666;
  transition: all 0.3s ease;
}

body.dark-theme .sammi-zibll-comment-dark-mode-toggle svg {
  fill: #e0e0e0;
}

/* 暗色模式过渡效果 */
body.dark-theme-transition,
body.dark-theme-transition * {
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease !important;
}