:root {
  --primary: #13243d;
  --blue: #2497f4;
  --star: #ffd600;
  --success: #34d399;
  --grey: #f3f6fb;
  --bg: #fafdff;
  --radius: 14px;
  --avatar-bd: #e1e1e1;
  --chip: #eaf3ff;
}


.review-bg {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.review-wrapper {

  border-radius: 32px;
  padding: 2.4rem 2.3rem 2.5rem 2.2rem;
  width: 100%;
  margin: auto;
  box-shadow: 0 20px 80px #28477422;
}

.section-title {
  text-align: center;
  font-weight: 700;
  font-size: 3.3rem;
  margin-top: 36px;
  color: white;
  text-transform: uppercase;
}

/* //popup for */
.popup-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999;
}

.popup-content {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 30%;
  height: 65vh;
  background: #fff;
  border-radius: 8px;
  position: relative;
}

.close-btn {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 24px;
  cursor: pointer;
  color: red;
}

/* last */
.review-form {
  width: 90%;
  height: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;

  padding-block: 4rem;
  flex-direction: column;
  border-radius: 20px;
}

.review-form #message {
  height: 8rem;
}

.review-form input,
.review-form select {
  background: transparent;
  font-size: 1.5rem;
  border-radius: 5px;
  box-shadow: 0 0 2px rgb(90, 88, 88);
  height: 4rem;
  width: 90%;
  padding-inline-start: 0.5rem;
  outline: none;
  transition: border-bottom .18s;
}

.review-form input:focus,
.review-form select:focus {
  border-bottom: 1px solid var(--blue);
}

.review-form .btn {
  background: rgb(252, 206, 0);
  color: white;
  font-weight: 700;
  font-size: 1.3rem;
  border: none;
  padding: 1rem 2rem;
  cursor: pointer;
  box-shadow: 0 1px 10px #dbeefa44;
  transition: background .18s, opacity .15s;
}

.review-form .btn:disabled {
  background: #b6dfff;
  opacity: .5;

}

.overview-box {
  border-radius: 24px;
  box-shadow: 0 6px 28px #b8e3ff10;
  padding: 1.7rem 1.3rem;
  /* min-width: 238px;
  max-width: 340px; */
}

.overview-score {
  font-size: 2.7rem;
  font-weight: 900;
  color: var(--star);
  display: flex;
  align-items: center;
  justify-content: center;
}

.overview-score i {
  margin-right: .5rem;
}

.overview-score .divider {
  font-size: 1.47rem;
  color: #bdbdbd;
  font-weight: 500;
  margin-left: .44rem;
}

.overview-count {
  margin: .7rem 0 1.5rem 0;
  font-size: 1.09rem;
  color: #7d8bad;
  text-align: center;
}

.bar-list {
  width: 60%;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.sort-bar {
  display: flex;
  flex-direction: column;

  justify-content: space-around;

}

.bar-row {
  display: flex;
  align-items: center;
  gap: 1rem;
}

#openPopupBtn {
  width: 10rem;
  height: 3rem;
  cursor: pointer;
  background-color: #94ee94;
  color: rgb(11, 53, 143);
}

#openPopupBtn:hover {
  box-shadow: 0 0 20px #94ee94;
}

.bar-label {
  min-width: 2.1rem;
  font-weight: 600;
  color: #6cafcd;
  letter-spacing: .04em;
}

.bar-container {
  flex: 1;
  background: #e3eee2;
  border-radius: 10px;
  overflow: hidden;
  height: 8px;
}

.bar-fill {
  background: var(--blue);
  height: 100%;
  width: 0;
  border-radius: 10px;
  transition: width 1.05s cubic-bezier(.48, 0, .18, 1);
}

.bar-perc {
  width: 38px;
  text-align: right;
  font-size: 1.03em;
  color: #4e4e7f;
  font-weight: 500;
}

.reviews-main {
  display: flex;
  gap: 2.8rem;
  flex-direction: column;
}

.reviews-box {
  flex: 1;
  border-radius: 20px;
  padding: 20px;
}

.reviews-tabs {
  display: flex;
  gap: 13rem;
  margin-bottom: 1em;
}

.tab-btn {
  height: 3rem;
  width: 10rem;
  background: var(--chip);
  font-weight: 700;
  font-size: 1.07rem;
  border: none;
  border-radius: 14px;
  color: green;
  transition: background .18s, color .18s, border .18s;
  font-family: inherit;
  cursor: pointer;
}

.tab-btn.active,
.tab-btn:focus {
  background: #fff;
  color: var(--blue);
  border: 2px solid var(--blue);
  box-shadow: 0 1.5px 8px #d0e6ff17;
}

.reviews-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(35rem, auto));
  gap: 2.3rem;
  margin-top: 4.1rem;
  justify-content: center;
  align-items: center;

  /* box-shadow: 0 0 10px goldenrod; */
}

.review-card {
  /* background: #fafdff; */
  border-radius: 18px;
  box-shadow: 0 7px 18px #e2f2e017;
  padding: 1.22rem 1.2rem .78rem 1.21rem;
  display: flex;
  flex-direction: column;
  font-size: 1.1rem;
  cursor: pointer;
  box-shadow: 0 0 5px grey;
  transition: box-shadow .18s;
}

.review-card:hover {
  background: #ffffff;

}

.review-card:hover .card-name {
  color: rgb(0, 110, 255);
}

.review-card:hover .card-gmail {
  color: #13243d;
}

.review-card:hover .card-content {
  color: black;
}

.review-card:hover .card-actions {

  color: #5385ab;
}

.card-top {
  display: flex;
  gap: 1.16rem;
  align-items: center;
  margin-bottom: 10px;
}

.card-avatar {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  object-fit: cover;
  border: 2.7px solid var(--avatar-bd);
}

.card-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2.5px;

}

.card-name {
  font-weight: 700;
  letter-spacing: .03em;
  font-size: 1.15rem;
  color: white;
}

.card-gmail {
  font-size: 1em;
  color: #298e9f;
  font-weight: 500;
  color: white;
}

.card-rating {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  font-size: 1.21rem;
  color: #18abfa;
  font-weight: 700;
  margin-left: auto;
  color: rgb(245, 189, 8);
}


.card-content {
  margin: 5px 0 13px 2px;
  padding-left: 1px;
  color: white;
  font-size: 1.03rem;
  font-weight: 500;
  letter-spacing: .018em;
}

.card-actions {
  display: flex;
  gap: 1.55rem;
  color: #5385ab;
  font-size: 1.07em;
  align-items: center;
  color: white;
}

.card-actions button {
  background: none;
  border: none;
  font: inherit;
  color: inherit;
  display: inline-flex;
  align-items: center;
  gap: .33em;
  cursor: pointer;
  font-weight: 600;
  transition: color .14s;
}

.card-actions button.liked,
.card-actions button:active {
  color: #2497f4;
}

.card-actions button .delete-btn {
  color: #fa5252;
  font-weight: 600;
  margin-left: auto;
  border-radius: 6px;
  padding: .19em .9em;
  transition: background .18s;
}

.card-actions button .delete-btn:hover {
  background: #fa525216;
}

.card-actions button:focus {
  outline: 2px solid #2ec8fa;
}

.popup-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 150;
  background: rgba(0, 0, 0, .10);
}

.popup-card {
  background: linear-gradient(97deg, #2497f4 70%, #28cf74 100%);
  color: #fff;
  border-radius: 20px;
  box-shadow: 0 14px 48px #1363df55;
  padding: 2.3rem 2.8rem;
  font-size: 2.1rem;
  font-weight: 700;
  display: flex;
  flex-direction: column;
  align-items: center;
  animation: popIn .55s;
}

.popup-card i {
  font-size: 3rem;
  margin-bottom: .6em;
  filter: drop-shadow(0 2px 11px #fff7);
}

@keyframes popIn {
  from {
    opacity: 0;
    transform: scale(.7);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

.modal-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 900;
  background: rgba(0, 0, 0, .14);
}

.modal-card {
  background: #fff;
  border-radius: 17px;
  padding: 2.1rem 2.3rem;
  box-shadow: 0 7px 28px #1e5b9c2b;
  color: #1a2b48;
  font-size: 1.14rem;
  text-align: center;
}

#modal-close {
  margin-top: 1.2em;
  background: var(--blue);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 1.09em;
  font-weight: 600;
  padding: .7em 2.1em;
  cursor: pointer;
  box-shadow: 0 2px 10px #2497f420;
}

#modal-close:hover {
  background: #1b7cd8;
}

.popup-main {}

@media (max-width: 900px) {
  .review-wrapper {
    padding: 0.8rem 0.3rem;
  }

  .reviews-main {
    flex-direction: column;
  }

  .reviews-tabs {
    gap: 2rem;
  }

  .bar-list {
    width: 60%;
  }

  #openPopupBtn {
    width: 14rem;
    height: 5rem;
  }

  .popup-content {
    /* min-width: 55vw; */
    width: 60%;
  }
  .review-form {
    padding-block: 10rem;
  }
}

@media (max-width: 600px) {
  .sort-bar {
    display: block;
    margin-block: 3rem;
  }

  .popup-main {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
  }

  .reviews-tabs {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
  }

  #openPopupBtn {
    width: 13rem;
    height: 4rem;

  }

  .overview-box,
  .reviews-box {
    max-width: 100%;
  }

  .bar-list {
    width: 100%;
  }

  .popup-card {
    padding: 1rem 1.1rem;
    font-size: 1.12rem;
  }

  .modal-card {
    padding: 1rem 0.6rem;
    font-size: 1.04rem;
  }

  .review-form {
    flex-direction: column;
  }

  .card-actions {
    flex-wrap: wrap;
  }

  .review-card {
    box-shadow: none;
  }

  .popup-content {
    width: 80%;
  }
}

@media (max-width: 400px) {
  .popup-content {
    min-width:75vw;
    height:55%;
  }
}

/* Extra clarity for review fields */
.card-name::before {
  color: #4da1f7;
  font-weight: 700;
}

/* content: "Email: "; */
.card-gmail::before {
  color: #2b8e9f;
  font-weight: 600;
}

.card-content::before {
  content: "Message: ";
  color: #28cbfa;
  font-weight: 600;
}