
.ust-comments {
  margin-top: 40px;
  padding: 0;
  background: transparent;
}

.ust-comments-head {
  display: flex;
  gap: 20px;
  justify-content: space-between;
  align-items: flex-end;
  flex-wrap: wrap;
  margin-bottom: 18px;
}

.ust-comments-title {
  margin: 0 0 6px;
  color: #111827;
  font-size: 40px;
  line-height: 1.15;
  font-weight: 700;
}

.ust-comments-title span {
  color: #6b7280;
  font-weight: 600;
}

.ust-comments-subtitle,
.ust-comment-note,
.ust-comment-voted-note {
  margin: 0;
  color: #6b7280;
  font-size: 15px;
  line-height: 1.6;
}

.ust-comments-sort {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.ust-sort-button,
.ust-comments-more,
.ust-vote-button,
.ust-comment-submit,
.ust-comment-link {
  border: 1px solid #d1d5db;
  border-radius: 14px;
  cursor: pointer;
  transition: all .2s ease;
  background: #fff;
}

.ust-sort-button {
  padding: 13px 18px;
  color: #4b5563;
  font-size: 16px;
  line-height: 1;
  font-weight: 600;
  box-shadow: 0 1px 1px rgba(15, 23, 42, 0.02);
}

.ust-sort-button:hover,
.ust-sort-button:focus {
  border-color: #94a3b8;
  color: #111827;
  outline: 0;
}

.ust-sort-button.is-active {
  color: #2563eb;
  border-color: #4f8cff;
  box-shadow: 0 0 0 2px rgba(79, 140, 255, 0.06) inset;
}

.ust-comments-list {
  display: grid;
  gap: 14px;
}

.ust-comments-list.is-loading {
  opacity: .65;
}

.ust-comment-card {
  display: grid;
  grid-template-columns: 64px 1fr auto;
  gap: 18px;
  padding: 20px 18px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 18px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.03);
}

.ust-comment-avatar {
  width: 58px;
  height: 58px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 18px;
  color: #35507a;
  background: #dbe7ff;
}

.ust-comment-card[data-avatar-tone="green"] .ust-comment-avatar {
  background: #d9f2d4;
  color: #347b2d;
}

.ust-comment-card[data-avatar-tone="yellow"] .ust-comment-avatar {
  background: #f6edc9;
  color: #977321;
}

.ust-comment-card[data-avatar-tone="purple"] .ust-comment-avatar {
  background: #e7dcff;
  color: #6f52b1;
}

.ust-comment-card[data-avatar-tone="blue"] .ust-comment-avatar {
  background: #dbe7ff;
  color: #35507a;
}

.ust-comment-main {
  min-width: 0;
}

.ust-comment-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  margin-bottom: 8px;
}

.ust-comment-author {
  color: #111827;
  font-size: 20px;
  line-height: 1.25;
  font-weight: 700;
}

.ust-comment-date {
  color: #6b7280;
  font-size: 14px;
}

.ust-comment-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 12px;
  border: 1px solid #f2d48b;
  background: #fff9e9;
  color: #a56a00;
  font-size: 14px;
  font-weight: 600;
}

.ust-comment-content {
  color: #374151;
  font-size: 17px;
  line-height: 1.7;
}

.ust-comment-content p {
  margin: 0 0 10px;
}

.ust-comment-content p:last-child {
  margin-bottom: 0;
}

.ust-comment-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.ust-comment-link {
  padding: 0;
  border: 0;
  background: transparent;
  color: #6b7280;
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
}

.ust-comment-link:hover {
  color: #111827;
}

.ust-comment-votes {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 140px;
}

.ust-vote-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 46px;
  padding: 10px 14px;
  color: #111827;
  font-size: 16px;
  font-weight: 600;
}

.ust-vote-button:hover {
  border-color: #cbd5e1;
  background: #f8fafc;
}

.ust-vote-button.is-disabled,
.ust-vote-button:disabled {
  opacity: .72;
  cursor: default;
}

.ust-comments-more-wrap {
  display: flex;
  justify-content: center;
  margin-top: 14px;
}

.ust-comments-more,
.ust-comment-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px 26px;
  color: #2563eb;
  border-color: #4f8cff;
  background: #fff;
  font-size: 16px;
  font-weight: 700;
}

.ust-comments-more:hover,
.ust-comment-submit:hover {
  background: #f8fbff;
}

.ust-comments-empty {
  padding: 22px;
  background: #fff;
  border: 1px dashed #d1d5db;
  border-radius: 18px;
  color: #6b7280;
}

.ust-comments-form-wrap {
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid #e5e7eb;
}

.ust-comments .comment-reply-title {
  margin: 0 0 14px;
  color: #111827;
  font-size: 30px;
  line-height: 1.2;
}

.ust-comments form.comment-form {
  display: grid;
  gap: 14px;
}

.ust-comments .comment-form-author,
.ust-comments .comment-form-email,
.ust-comments .comment-form-comment,
.ust-comments .comment-form-cookies-consent {
  margin: 0;
}

.ust-comments label {
  display: block;
  margin-bottom: 6px;
  color: #111827;
  font-size: 15px;
  font-weight: 600;
}

.ust-comments input[type="text"],
.ust-comments input[type="email"],
.ust-comments textarea {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid #d1d5db;
  border-radius: 16px;
  padding: 14px 16px;
  background: #fff;
  color: #111827;
  transition: border-color .2s ease, box-shadow .2s ease;
}

.ust-comments input[type="text"]:focus,
.ust-comments input[type="email"]:focus,
.ust-comments textarea:focus {
  border-color: #4f8cff;
  outline: 0;
  box-shadow: 0 0 0 3px rgba(79, 140, 255, 0.08);
}

.ust-comments textarea {
  min-height: 140px;
  resize: vertical;
}

@media (max-width: 921px) {
  .ust-comments-title {
    font-size: 34px;
  }

  .ust-comment-card {
    grid-template-columns: 56px 1fr;
  }

  .ust-comment-votes {
    grid-column: 2;
    flex-direction: row;
    justify-content: flex-start;
    min-width: 0;
  }

  .ust-comment-author {
    font-size: 18px;
  }

  .ust-comment-content {
    font-size: 16px;
  }
}

@media (max-width: 544px) {
  .ust-comments-head {
    align-items: flex-start;
  }

  .ust-comments-title {
    font-size: 30px;
  }

  .ust-sort-button {
    width: 100%;
  }

  .ust-comment-card {
    grid-template-columns: 1fr;
    gap: 14px;
    padding: 16px;
  }

  .ust-comment-avatar {
    width: 52px;
    height: 52px;
    font-size: 17px;
  }

  .ust-comment-votes {
    grid-column: auto;
  }

  .ust-vote-button {
    flex: 1 1 auto;
  }

  .ust-comments-more,
  .ust-comment-submit {
    width: 100%;
  }
}


.ust-comment-note-user {
  margin-top: -4px;
}

.ust-comments .form-submit {
  margin: 0;
}

.ust-comments .required {
  color: #dc2626;
}
