/* Container */

.d1-comments__heading {
  margin: 1rem 0;
  font-size: 1.25rem;
  font-weight: 600;
}

/* List */
.d1-comments__list {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.d1-comments__item {
  margin: 0 0 1rem 0;
}

/* Nested replies */
.d1-replies {
  list-style: none;
  padding-left: 1rem;
  margin-top: 0.75rem;
}

.d1-reply-btn {
  cursor: pointer;
}

.d1-reply-disabled {
  opacity: 0.6;
}

/* Article */
.d1-comment {
  padding: 0.5rem;
  border: 1px solid rgba(0, 0, 0, 0.08);
 /* border-radius: 0.5rem; */
  background: rgba(0, 0, 0, 0.02);
}

.d1-comment__meta {
  font-size: 0.95rem;
  margin: 0 0 0.5rem 0;
  color: inherit;
  opacity: 0.9;
}

.d1-comment__author {
  font-weight: 600;
}

.d1-comment__website {
  word-break: break-word;
}

.d1-comment__time {
  opacity: 0.9;
}

.d1-comment__sep {
  opacity: 0.6;
  margin: 0 0.17rem;
}

.d1-comment__below_name {
  margin-top: 0.25rem;
  line-height: 1.45;
}

/* Body */
.d1-comment__body {
  white-space: pre-wrap;
  word-wrap: break-word;
  line-height: 1.45;
  margin-bottom: 0.5rem;
  padding: 0.5rem;
}

/* Reply UX */
.d1-replying-hint {
  margin: 0.25rem 0 0.75rem 0;
  padding: 0.25rem 0.5rem;
  background: rgba(0, 0, 0, 0.05);
  border: 1px dashed rgba(0, 0, 0, 0.2);
 /* border-radius: 0.375rem; */
  font-size: 0.9rem;
}

.d1-cancel-reply {
  margin-left: 0.5rem;
  background: transparent;
  border: none;
  text-decoration: underline;
  cursor: pointer;
}

.d1-closed-note {
    padding: .5rem;
    opacity: 0.9;
}


/* Avatar */
.d1-comment__avatar {
  display: inline-block;
  vertical-align: middle;
  /* border-radius: 50%; */
  margin-right: 0.5rem;
}

/* Child comment hint */
.d1-comment__replying-note {
  margin-top: 0;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
  opacity: 0.9;
}

/* Form */
.d1-form {
  padding: 1rem;
  border: 1px solid rgba(0, 0, 0, 0.1);
  /* border-radius: 0.5rem; */
  background: rgba(0, 0, 0, 0.02);
  max-width: 40rem;
}

.d1-form div {
  margin-bottom: 0.75rem;
}

.d1-form label {
  display: block;
  margin-bottom: 0.25rem;
  font-size: 0.95rem;
}

.d1-form input[type="text"],
.d1-form input[type="email"],
.d1-form input[type="url"],
.d1-form textarea {
  width: 100%;
  padding: 0.5rem 0.65rem;
  font-size: 1rem;
  border: 1px solid rgba(0, 0, 0, 0.15);
  /* border-radius: 0.375rem; */
  box-sizing: border-box;
}

.d1-form input:focus,
.d1-form textarea:focus {
  outline: none;
  border-color: rgba(0, 0, 0, 0.3);
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.08);
}

.d1-form .d1-invalid {
  border-color: #b00020;
  box-shadow: 0 0 0 2px rgba(176, 0, 32, 0.2);
}

.d1-form textarea {
  resize: vertical;
  line-height: 1.45;
}

.d1-form button[type="submit"] {
  display: inline-block;
  padding: 0.5rem 1rem;
  /* border-radius: 0.375rem; */
  border: 1px solid rgba(0, 0, 0, 0.2);
  background: rgba(0, 0, 0, 0.05);
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}

.d1-form button[type="submit"]:hover {
  background: rgba(0, 0, 0, 0.08);
  border-color: rgba(0, 0, 0, 0.3);
}

.d1-form__heading {
  font-weight: 600;
  font-size: 1.25rem;  
}

#d1-msg {
  font-size: 0.95rem;
}

/* Reviews */
.d1-reviews__summary {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0 0.75rem 0;
}

.d1-reviews__list {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.d1-reviews__item {
  margin: 0 0 1rem 0;
  padding: 0.5rem;
  border: 1px solid rgba(0, 0, 0, 0.08);
  background: rgba(0, 0, 0, 0.02);
}

.d1-reviews__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.35rem;
}

.d1-reviews__name {
  font-weight: 600;
}

.d1-reviews__date {
  opacity: 0.8;
  font-size: 0.9rem;
}

.d1-reviews__content {
  white-space: pre-wrap;
  word-wrap: break-word;
  line-height: 1.45;
}

.d1-reviews__empty {
  opacity: 0.85;
}

/* Rating display */
.d1-rating {
  position: relative;
  display: inline-block;
  line-height: 1;
  letter-spacing: 2px;
  font-size: 1rem;
}

.d1-rating--small {
  font-size: 0.9rem;
}

.d1-rating__base {
  color: #c0c0c0;
}

.d1-rating__fill {
  position: absolute;
  left: 0;
  top: 0;
  color: #f3a120;
  overflow: hidden;
  white-space: nowrap;
}

/* Rating input */
.d1-rating-input__stars {
  display: inline-flex;
  flex-direction: row-reverse;
  gap: 0.25rem;
}

.d1-rating-input__stars input {
  display: none;
}

.d1-rating-input__stars label {
  cursor: pointer;
  color: #c0c0c0;
  font-size: 1.2rem;
  line-height: 1;
}

.d1-rating-input__stars input:checked ~ label {
  color: #f3a120;
}

.d1-rating-input__stars label:hover,
.d1-rating-input__stars label:hover ~ label {
  color: #f3a120;
}
