/* fix202: comment interactivity (poll tick + anonymous likes)
 * fix209: inline reply UI + new-comment highlight
 *
 * What it does:
 * - Styles the Like button + count appended below each comment.
 * - Styles an inline reply form that posts via AJAX (no page reload).
 * - Styles a lightweight polling indicator for background refresh.
 */

.sc4-comment-actions {
  margin-top: 10px;
  display: flex;
  gap: 8px;
  align-items: center;
}

.sc4-comment-like {
  display: inline-flex;
  gap: 10px;
  align-items: center;
}

.sc4-comment-like-count {
  font-weight: 600;
  min-width: 1.6em;
  text-align: right;
}


.sc4-comment-reply-btn {
  white-space: nowrap;
}

.sc4-comment-reply-slot {
  margin-top: 10px;
}

.sc4-comment-reply-form {
  padding: 10px;
  border-radius: 14px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.10);
  display: grid;
  gap: 8px;
}

.sc4-comment-reply-form textarea {
  width: 100%;
  min-height: 92px;
  resize: vertical;
}

.sc4-comment-reply-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: flex-end;
}

.sc4-comment-new {
  outline: 2px solid rgba(255,255,255,0.16);
  border-radius: 14px;
  animation: sc4CommentFlash 2.4s ease-out 1;
}

@keyframes sc4CommentFlash {
  0% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.18); }
  35% { box-shadow: 0 0 0 6px rgba(255, 255, 255, 0.10); }
  100% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.00); }
}

.sc4-comments-poll-indicator {
  font-size: 0.92em;
  opacity: 0.75;
  margin-top: 8px;
  display: none;
}

.sc4-comments-polling .sc4-comments-poll-indicator {
  display: block;
}

/* fix203: "New comments" toast (keeps audio playing; no page reload) */
.sc4-comments-toast {
  position: fixed;
  left: 12px;
  right: 12px;
  bottom: 12px;
  z-index: 1000001; /* keep below GDPR banner (fix197) */
  display: none;
  pointer-events: none;
}

.sc4-comments-toast.is-visible {
  display: block;
}

.sc4-comments-toast__inner {
  pointer-events: auto;
  max-width: 560px;
  margin: 0 auto;
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(14, 14, 14, 0.92);
  border: 1px solid rgba(255,255,255,0.12);
  box-shadow: 0 10px 30px rgba(0,0,0,0.35);
}

.sc4-comments-toast__text {
  font-weight: 600;
  opacity: 0.92;
  flex: 1;
}

.sc4-comments-toast__btn {
  white-space: nowrap;
}

.sc4-comments-toast__close {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

/* Abrasive skin pass (fix216)
 * Keep scope tight to comment areas so themes stay intact elsewhere.
 */
#comments, .comments-area {
  color: rgba(255,255,255,0.92);
}

.comment-respond, #respond {
  margin-top: 18px;
  padding: 16px;
  border-radius: 18px;
  background: rgba(0,0,0,0.55);
  border: 1px solid rgba(255,255,255,0.10);
  box-shadow: 0 12px 34px rgba(0,0,0,0.30);
  backdrop-filter: blur(6px);
}

.comment-respond .comment-reply-title,
#respond .comment-reply-title {
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 800;
  opacity: 0.92;
}

#commentform textarea,
#commentform input[type="text"],
#commentform input[type="email"],
#commentform input[type="url"],
.comment-respond textarea,
.comment-respond input[type="text"],
.comment-respond input[type="email"],
.comment-respond input[type="url"] {
  width: 100%;
  border-radius: 14px;
  padding: 12px 12px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.14);
  color: rgba(255,255,255,0.92);
  outline: none;
}

#commentform textarea:focus,
#commentform input:focus,
.comment-respond textarea:focus,
.comment-respond input:focus {
  border-color: rgba(255,255,255,0.24);
  box-shadow: 0 0 0 4px rgba(255,255,255,0.06);
}

#commentform .form-submit input[type="submit"],
#commentform button[type="submit"],
.comment-respond .form-submit input[type="submit"],
.comment-respond button[type="submit"] {
  border-radius: 16px;
  padding: 10px 16px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* Comment cards */
.comment-list > li, .commentlist > li {
  border-radius: 18px;
  background: rgba(0,0,0,0.35);
  border: 1px solid rgba(255,255,255,0.08);
  padding: 12px;
  margin-bottom: 12px;
}

.comment-list .children > li,
.commentlist .children > li {
  margin-top: 10px;
  background: rgba(255,255,255,0.03);
}
