/* CUSTOMERS FEEDBACK PAGE */

.customers-feedback-wrapper {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.customers-feedback-form-wrapper {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.feedback-section {
  padding-top: 100px;
  padding-bottom: 40px;
  background-color: var(--color-bg);
}

@media (max-width: 991px) {
  .feedback-section__rows {
    flex-direction: column-reverse;
    align-items: center;
  }
}

.customers-feedback-header {
  text-align: center;
  font-family: Roboto, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
  font-size: 2rem;
  font-weight: 600;
  margin: 4rem 0 2rem 0;
}

.customers-feedback-form {
  position: relative;
  max-width: 600px;
  width: 100%;
  padding: 2rem 1.5rem 3rem 1.5rem;
  border-radius: var(--radius);
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  color: var(--color-text-primary);
  font-family: Roboto, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
  transition: 0.3s;
  opacity: 1;
  box-shadow: var(--shadow-soft);
}

.customers-feedback-reviews {
  width: 100%;
}

.customers-feedback-form-title {
  color: var(--color-text-primary);
  font-size: 1.5rem;
}

.customers-feedback-form-text {
  color: var(--color-text-secondary);
  font-size: 0.9rem;
}

.feedback-success {
  z-index: -1;
  width: 100%;
  height: 100%;
  background-color: var(--color-surface);
  font-family: Roboto, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
  font-size: 2rem;
  opacity: 0;
  transition: 0.3s;
  position: absolute;
  top: 0;
  left: 0;
  /* top: 20%;
    left: 50%;
    transform: translate(-50%, -50%); */
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: var(--radius);
}

.customers-feedback-form.submited .feedback-success {
  opacity: 1;
  z-index: 1;
}

@media (min-width: 576px) {
  .form__item {
    display: flex;
    align-items: center;
  }
}

.simple-rating {
  position: relative;
  font-size: 2rem;
  display: inline-block;
}

.simple-rating::before {
  display: block;
  content: '★★★★★';
  color: var(--color-accent);
}

.simple-rating__items {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  display: flex;
  flex-direction: row-reverse;
  overflow: hidden;
}

.simple-rating__item {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  /* visibility: hidden; */
  top: 45px;
  left: 83px;
}

.simple-rating__item:checked,
.simple-rating__item:checked ~ .simple-rating__label {
  color: #f7c440;
}

.simple-rating__label {
  flex: 0 0 20%;
  height: 100%;
  cursor: pointer;
  color: var(--color-surface-alt);
}

.simple-rating__label::before {
  content: '★';
  display: block;
  transition: color 0.3s ease 0s;
}

.simple-rating__label:hover,
.simple-rating__label:hover ~ .simple-rating__label,
.simple-rating__label:checked ~ .simple-rating__label:hover {
  color: #f7c440;
}

.customers-feedback-form-label {
  font-size: 0.8rem;
  color: var(--color-text-primary);
  font-weight: 600;
  margin-bottom: 0.4rem;
}
.customers-feedback-form-input {
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  display: block;
  width: 100%;
  padding: 0.5rem 1rem;
  transition: all 0.2s;
  margin-bottom: 0.8rem;
}

.customers-feedback-form-input:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px rgba(168, 159, 148, 0.3);
}

.customers-feedback-form-button {
  width: 100%;
  color: var(--color-bg);
  background-color: var(--color-text-primary);
  cursor: pointer;
  transition: all 0.2s;
  border-radius: var(--radius);
  padding: 0.5rem;
  border: none;
}

.customers-feedback-form-button:hover {
  width: 100%;
  color: var(--color-bg);
  background-color: rgba(45, 42, 38, 0.8);
}

/*.client-feedback*/
.client-feedback {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

@media (max-width: 768px) {
  .client-feedback {
    grid-template-columns: 1fr;
  }
}

.client-feedback__feedback {
  width: 100%;
  padding: 1rem 1.5rem 2rem 1.5rem;
  border-radius: var(--radius);
  background-color: var(--color-surface);
  color: var(--color-text-secondary);
  font-family: Roboto, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
  margin-bottom: 1rem;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-soft);
}

.client-feedback__feedback.answer {
  margin-left: auto;
  background-color: var(--color-surface-alt);
  color: #656970;
  width: 80%;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-soft);
}

.client-feedback__photo-and-name {
  display: flex;
  align-items: center;
  margin-bottom: 0.5rem;
}

.client-feedback__name {
  color: var(--color-text-primary);
  font-weight: 600;
}

.client-feedback__photo-and-name.answer {
  flex-direction: row-reverse;
}

.client-feedback__photo {
  margin-right: 10px;
}

.client-feedback__photo.answer {
  margin-right: 0;
  margin-left: 10px;
}

.client-feedback__photo-img {
  width: 48px;
  height: 48px;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: var(--color-bg);
  border-radius: 50%;
}

.client-feedback__photo-img img {
  width: 100%;
  border-radius: 50%;
  object-fit: cover;
  height: 100%;
}

.client-feedback__date {
  text-align: right;
  font-size: 0.8rem;
  color: var(--color-text-secondary);
}

.client-feedback__answer-position {
  font-size: 0.8rem;
  color: var(--color-text-secondary);
  font-style: italic;
}

.rating {
  height: 1rem;
  width: 100px;
  position: relative;
  --starWidth: 25%;
}

.client-feedback__date-and-rating {
  display: flex;
  justify-content: space-between;
}

.rating .reviews-star-grey {
  background-size: 100px;
  background-repeat: no-repeat;
  width: 100%;
  height: 100%;
  background-image: url('../images/gray-star.svg');
}

.rating .reviews-star {
  width: var(--starWidth);
  background-image: url('../images/star.svg');
  background-size: 100px;
  background-repeat: no-repeat;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
}

.client-feedback__text {
  margin-top: 0.5rem;
}
.client-feedback__footer {
  padding: 0;
  margin: 0;
}

@media (max-width: 576px) {
  .client-feedback__feedback {
    width: 95%;
    padding-left: 10px;
    padding-right: 10px;
  }

  .client-feedback__date {
    padding-right: 14px;
  }
}
