:root {
  	/* Global Spacing */
	--gru-spacing: 8px;
	--gru-gutter-x: calc(var(--gru-spacing) * 4);
}

.course-review-container {
  position: relative;
}

.review-wrapper > h2 {
  font-size: 24px;
  font-weight: 600;
  margin: 0 0 16px;
}

/* Review sumary */
.review-sumary {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  margin-bottom: 24px;
}

.avg-rating-wrap {
  background-color: #F0F6F6;
  border-radius: 6px;
  flex-basis: 100%;
  margin-bottom: 24px;
  padding: 16px 32px;
  min-width: 120px;
  text-align: center;
}

@media (min-width: 768px) {
  .avg-rating-wrap {
    flex-basis: auto;
    margin-bottom: 0;
  }
}

.avg-rating-wrap .rating-number {
  color: #111827;
  font-size: 64px;
  font-weight: 600;
  line-height: 1;
  margin-bottom: var(--gru-spacing);
}

.avg-rating-wrap .rating-label {
  font-size: 14px;
}

.rating-list {
  flex: 1;
}

@media (min-width: 576px) {
  .rating-list {
    padding-left: 24px;
  }
}

/* Avg rating */
.rating-star-wrap {
  display: flex;
  align-items: center;
  margin-bottom: var(--gru-spacing);
}

.avg-star {
  flex: 1;
  display: flex;
  padding-left: 24px;
  align-items: center;
}

.avg-star .bar-full {
  background: #e5e7eb;
  border-radius: 4px;
  flex: 1;
  padding: 2px;
}

.avg-star .bar-active {
  background: #2563EB;
  border-radius: 6px;
  min-height: 6px;
}

.avg-star span {
  font-size: 14px;
  font-weight: 500;
  min-width: 60px;
  text-align: right;
}

.review-heading {
  border-top: 1px solid #e5e7eb;
  display: flex;
  align-items: center;
  padding-top: 56px;
  justify-content: space-between;
}

.review-heading h2 {
  font-size: 24px;
  margin: 0;
}

/* Review item */
.review-list {
  margin-top: calc(var(--gru-spacing) * 3);
}

.review-item {
  display: flex;
  align-items: flex-start;
  margin-bottom: calc(var(--gru-spacing) * 3);
}

.review-item + .review-item {
  border-top: 1px solid #e2e8f0;
  padding-top: calc(var(--gru-spacing) * 3);
}

.user-info {
  margin-bottom: var(--gru-spacing);
  padding-left: 64px;
  position: relative;
}

@media(min-width: 576px) {
  .user-info {
    margin-bottom: 0;
    padding-left: 80px;
  } 
}

.user-avatar {
  border-radius: 50%;
  box-shadow: 0 2px 5px rgba(0,0,0,0.2);
  position: absolute;
  left: 0;
  top: 8px;
  width: 48px;
  overflow: hidden;
}

@media (min-width: 576px) {
  .user-avatar {
    top: 4px;
    width: 56px;
  }
}

.review-content {
  flex: 1;
}

.review-content .review-text {

}

@media (min-width: 576px) {
  .review-content .review-text {
    padding-left: 80px;
  }
}

.review-content .user-name {
}

.review-content .user-name h5 {
  display: inline-block;
  font-size: 16px;
  font-weight: 600;
  position: relative;
}

.is-yours .review-content .user-name span {
  background: #f0fdf4;
  border-radius: 6px 6px 6px 0;
  border: 1px solid #86efac;
  color: #16a34a;
  font-weight: 500;
  padding: 2px 4px;
  position: absolute;
  top: -12px;
  right: -84px;
  font-size: 12px;
}

.review-content .review-meta {
  display: flex;
  align-items: center;
  margin-bottom: var(--gru-spacing);
}

.review-meta .user-rating {
  margin-right: var(--gru-spacing);
}

.review-meta .review-date {
  font-size: 14px;
}

.review-meta .review-date span {
  color: #6b7280;
}

/* Report */
.review-content .review-report {
  position: relative;
  margin-top: var(--gru-spacing);
}

.review-content .review-report-btn {
  border-bottom: 1px dotted #6b7280;
  color: #374151;
  font-size: 15px;
  font-weight: 400;
  transition: all 0.35s ease-in;
}

.review-content .review-report-btn:hover,
.review-content .review-report-btn:focus,
.review-content .review-report-btn:active {
  border-bottom: 1px dotted #2563EB;
  color: #2563EB;
}

.review-report .report-type-list {
  background-color: #fff;
  border: 1px solid #e5e7eb;
  box-shadow: 0 3px 5px rgba(0,0,0,0.1);
  border-radius: 6px;
  padding: 5px 0;
  position: absolute;
  top: auto;
  bottom: calc(100% + 1px);
  right: 0;
  text-align: left;
}

.review-report .report-type-list .report-type {
  padding: 6px 16px;
  transition: all 0.25s ease-in-out;
}

.review-report .report-type-list .report-type:hover {
  background-color: #f1f5f9;
  color: #2563eb;
  cursor: pointer;
}

.current-user-review {
  background: #f9fafb;
  border-radius: 6px;
  padding: 24px;
}

.current-user-review h2 {
  font-size: 20px;
  font-weight: 600;
  margin: 0 0 12px;
}

.current-user-review h3 {
  font-size: 18px;
  margin: 0;
}

.current-user-review .review-content {
  padding: 0;
  margin-bottom: calc(var(--gru-spacing) * 3);
}

.review-actions {
  text-align: right;
}

.review-actions button {
  background: #fff;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  color: #1f2937;
  display: inline-block;
  padding: 4px 12px;
  transition: all 0.25s ease-in-out;
}

.current-user-review button.review-edit:hover,
.current-user-review button.review-edit:focus,
.current-user-review button.review-edit:active {
  background-color: #15803D;
  border: 1px solid #15803D;
  color: #fff;
}

.current-user-review button.review-delete:hover,
.current-user-review button.review-delete:focus,
.current-user-review button.review-delete:active {
  background-color: #dc2626;
  border: 1px solid #dc2626;
  color: #fff;
}

.current-user-review .review-rating {
  display: flex;
  align-items: center;
  font-size: 15px;
  margin-bottom: 8px;
}

.current-user-review .review-rating span {
  display: inline-block;
  font-weight: 500;
  margin-right: 8px;
}

.current-user-review .review-time {
  font-size: 15px;
  margin-bottom: calc(var(--gru-spacing) * 2);
}

.current-user-review .review-time span {
  display: inline-block;
  font-weight: 500;
  margin-right: 8px;
}

.current-user-review .review-rating i,
.current-user-review .review-time i {
  color: #94A3B8;
  margin-right: 8px;
}

.current-user-review .review-actions {
  text-align: right;
}

.review-notice {
  background-color: #fff;
  border-radius: 6px;
  margin-bottom: calc(var(--gru-spacing) * 2);
  padding: 6px 12px;
}

.review-notice.review-pending {
  background-color: #ffedd5;
  color: #f97316;
}

.review-notice.review-unpublished {
  background-color: #fee2e2;
  color: #dc2626;
}

.review-loader {
  background: url(loading.gif) no-repeat center center rgba(255,255,255,0.8);
  backdrop-blur: blur(8px);
  display: none;
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 200;
}

.review-loader.active {  
  display: block;
}

.content-composer {
  clear: both;
}

.rating {
  border: none;
  display: inline-flex;
  flex-direction: row-reverse;
}

.rating > input {
  display: none;
}

.rating > label {
  background: url(../images/star.svg) no-repeat center center;
  display: inline-block;
  height: 16px;
  margin-right: 4px;
  width: 16px;
}

/***** CSS Magic to Highlight Stars on Hover *****/
.rating>input:checked~label,
/* show gold star when clicked */
.rating:not(:checked)>label:hover,
/* hover current star */
.rating:not(:checked)>label:hover~label {
  background: url(../images/star-on.svg) no-repeat center center;
}

/* hover previous stars in list */

.rating>input:checked+label:hover,
/* hover current star when changing rating */
.rating>input:checked~label:hover,
.rating>label:hover~input:checked~label,
/* lighten current selection */
.rating>input:checked~label:hover~label {
  background: url(../images/star-on.svg) no-repeat center center;
}

.rating-score {
  display: inline-flex;
  align-items: center;
}

.rating-score > label {
  background: url(../images/star.svg) no-repeat center center;
  display: inline-block;
  height: 16px;
  margin-right: 4px;
  width: 16px;
}

.rating-score > label.star-on {
  background: url(../images/star-on.svg) no-repeat center center;
}

/* .rating-score > label:before {
  margin-right: 4px;
  font-size: 15px;
  font-family: FontAwesome;
  display: inline-block;
  content: "\f005";
}

.rating-score > label:last-of-type::before {
  margin-right: 0;
} */

.review-report {
  position: relative;
  text-align: right;
}

.review-report.show .report-type-list {
  display: block;
}

.report-type-list {
  display: none;
  position: absolute;
  top: 20px;
  right: 0;
  background-color: #ddd;
}

/* Edit review */
.review-composer {
  border-top: 1px solid #e5e7eb;
  margin-bottom: calc(var(--gru-spacing) * 2);
  padding-top: 24px;
}

.review-composer h2 {
  font-size: 24px;
  font-weight: 600;
  margin: 0 0 16px;
}

.rating-selection {
  display: flex;
  align-items: center;  
  margin-bottom: var(--gru-spacing);
}

.rating-selection > div:first-of-type {
  padding-right: var(--gru-spacing);
}

.content-composer {
  margin-bottom: calc(var(--gru-spacing) * 2);
}

.content-composer textarea {
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  padding: 16px;
  width: 100%;
}

.review-actions .review-submit:hover,
.review-actions .review-submit:focus,
.review-actions .review-submit:active {
  background-color: #15803D;
  border: 1px solid #15803D;
  color: #fff;
}

.review-actions .review-cancel:hover,
.review-actions .review-cancel:focus,
.review-actions .review-cancel:active {
  background-color: #374151;
  border: 1px solid #374151;
  color: #fff;
}

/* Pagination */
.pagination-review {
  margin-bottom: calc(var(--gru-spacing) * 3);  
}

.pagination-review .pagination {
  justify-content: center;
}

.pagination-review ul.pagination .page-item span.page-link,
.pagination-review ul.pagination .page-item a {
  border-radius: 50% !important;
  min-width: 28px;
  padding: 2px 0;
  text-align: center;
}