/**
 * FARS TEC - Dark Gaming HUD Edition
 * Customized for PrestaShop Product Comments Module
 */

.product-comment-modal .material-icons[data-icon]:before,
.product-comment-list-item .material-icons[data-icon]:before,
.product-comments-additional-info .material-icons[data-icon]:before,
#product-comments-list-header .material-icons[data-icon]:before,
#product-comments-list-footer .material-icons[data-icon]:before {
  content: attr(data-icon);
}

/* ۱. دکمه‌های ثبت نظر و اکشن‌ها */
.btn-comment,
.btn-comment-inverse {
  height: 38px;
  border-radius: 8px;
  background: linear-gradient(135deg, #0088ff, #0044ff) !important;
  color: #ffffff !important;
  font-size: 13.5px;
  font-weight: 700;
  box-shadow: 0 4px 15px rgba(0, 136, 255, 0.35);
  padding: 8px 16px;
  border: none;
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.btn-comment .material-icons,
.btn-comment-inverse .material-icons {
  font-size: 19px;
  margin-right: 6px;
}

.btn-comment:hover {
  background: linear-gradient(135deg, #00a8ff, #0066ff) !important;
  box-shadow: 0 6px 20px rgba(0, 168, 255, 0.55) !important;
  transform: translateY(-2px);
}

.btn-comment-inverse {
  background: #17202e !important;
  color: #cbd5e1 !important;
  border: 1px solid #29384d !important;
  box-shadow: none;
}

.btn-comment-inverse:hover {
  background: #1f2a3d !important;
  border-color: #00f2fe !important;
  color: #ffffff !important;
  box-shadow: 0 0 12px rgba(0, 242, 254, 0.25) !important;
  transform: translateY(-2px);
}

.btn-comment-big {
  padding: 12px 20px;
  height: 44px;
}

.btn-comment-huge {
  padding: 12px 30px;
  height: 46px;
}

.link-comment {
  color: #00f2fe !important;
  transition: color 0.2s ease;
  font-weight: 600;
}

.link-comment:hover,
.link-comment:active {
  text-decoration: none;
  color: #38bdf8 !important;
  text-shadow: 0 0 8px rgba(0, 242, 254, 0.4);
}

/* ۲. بخش اطلاعات و امتیاز بالای صفحه محصول */
.product-comments-additional-info {
  margin: 18px 0;
  font-weight: 400;
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  font-size: 13.5px;
  color: #94a3b8;
}

.product-comments-additional-info .link-comment.post-product-comment {
  border-left: 1px solid #1f293d;
  padding-left: 14px;
  margin-left: 14px;
}

.product-comments-additional-info .comments-note {
  margin-right: 24px;
  margin-bottom: 12px;
}

/* ۳. مودال یا پاپ‌آپ ثبت نظر (Dark Modal) */
.product-comment-modal .modal-content {
  background-color: #121721 !important;
  border: 1px solid #1f2a3d !important;
  border-radius: 14px !important;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.8), 0 0 20px rgba(0, 136, 255, 0.15) !important;
  color: #e1e6ed !important;
}

.product-comment-modal .modal-header {
  border-bottom: 1px solid #1f293d !important;
  padding: 22px 25px 15px;
}

.product-comment-modal .modal-body {
  padding: 20px 25px 25px;
}

.product-comment-modal .modal-header .h2 {
  float: left;
  font-size: 19px;
  color: #ffffff;
  font-weight: 700;
}

.product-comment-modal .modal-dialog {
  width: calc(100% - 30px);
  max-width: 760px;
}

.product-comment-modal .modal-dialog .h3 {
  font-size: 14.5px;
  color: #cbd5e1;
}

.product-comment-modal .modal-dialog .product-flag {
  display: none;
}

.product-comment-modal .modal-dialog .product-cover,
.product-comment-modal .modal-dialog .product-cover img {
  width: 90px;
  height: 90px;
  border-radius: 10px;
  border: 1px solid #1f293d;
  background-color: #0b0e14;
}

.product-comment-modal label.form-label {
  font-size: 14px;
  margin: 10px 0 6px;
  color: #cbd5e1;
  font-weight: 600;
}

.product-comment-modal input {
  width: 100%;
  height: 42px;
  background-color: #17202e !important;
  border: 1px solid #29384d !important;
  color: #ffffff !important;
  border-radius: 8px !important;
  padding: 0 12px;
  outline: none;
  transition: border-color 0.25s ease;
}

.product-comment-modal input:focus {
  border-color: #00f2fe !important;
  box-shadow: 0 0 10px rgba(0, 242, 254, 0.25);
}

.product-comment-modal textarea {
  width: 100%;
  min-height: 90px;
  background-color: #17202e !important;
  border: 1px solid #29384d !important;
  color: #ffffff !important;
  border-radius: 8px !important;
  margin-bottom: 12px;
  padding: 10px 12px;
  outline: none;
  transition: border-color 0.25s ease;
}

.product-comment-modal textarea:focus {
  border-color: #00f2fe !important;
  box-shadow: 0 0 10px rgba(0, 242, 254, 0.25);
}

.product-comment-modal .btn-comment,
.product-comment-modal .btn-comment-inverse {
  font-size: 14.5px;
  line-height: 16px;
}

.product-comment-modal .required {
  font-size: 12px;
  margin-left: 5px;
  color: #ff3366;
}

.product-comment-modal .post-comment-buttons {
  display: flex;
  flex-direction: row;
  justify-content: flex-end;
  gap: 12px;
}

.product-comment-modal .post-comment-buttons .btn-comment {
  margin-left: 0;
}

#product-comment-posted-modal .post-comment-buttons,
#product-comment-post-error .post-comment-buttons,
#update-comment-usefulness-post-error .post-comment-buttons {
  margin-top: 25px;
}

.product-comment-modal .modal-header .material-icons {
  color: #00e676;
  font-size: 28px;
  line-height: 25px;
}

.product-comment-modal .modal-header .material-icons.error {
  color: #ff3366;
}

.product-comment-modal .modal-header .material-icons.feedback {
  color: #ffb703;
}

/* ۴. رتبه‌بندی و ستاره‌ها */
.star-content {
  margin: 0 0 0 5px;
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
}

.star-content div.star,
.star-content div.star-on,
.star-content div.star-hover {
  display: block;
  width: 20px;
  height: 20px;
  background: url(../img/stars.png) no-repeat 0 0 transparent;
  flex: auto;
  margin-left: 3px;
  filter: drop-shadow(0 0 3px rgba(255, 183, 3, 0.4));
}

.star-content div.star-on,
.star-content div.star-hover {
  background-position: -24px 0;
}

.small-stars .star-content div.star,
.small-stars .star-content div.star-on,
.small-stars .star-content div.star-hover {
  background: url(../img/small_stars.png) no-repeat 0 0 transparent;
  width: 16px;
  height: 16px;
  margin-left: 2px;
}

.small-stars .star-content div.star-on,
.small-stars .star-content div.star-hover {
  background-position: -19px 0;
}

.star-content div.star-hover {
  cursor: pointer;
}

.grade-stars {
  position: relative;
  height: 20px;
  min-width: 120px;
  display: inline-block;
}

.grade-stars.small-stars {
  min-width: 100px;
}

.grade-stars .star-content {
  position: absolute;
  top: 3px;
  left: 0;
}

.criterion-rating .grade-stars .star-content {
  top: 0;
}

#post-product-comment-modal .star-content div.star a {
  display: block;
  position: absolute;
  text-indent: -5000px;
}

#post-product-comment-modal .criterion-rating {
  display: flex;
  flex-direction: row;
  justify-content: flex-end;
  align-items: center;
}

#post-product-comment-modal .criterion-rating label {
  color: #cbd5e1;
  font-size: 14px;
  font-weight: 600;
  margin-left: 10px;
}

#ratingNotChosen {
  font-size: 12px;
  color: #ff3366;
  text-align: right;
  margin-top: 4px;
}

#post-product-comment-form input.error,
#post-product-comment-form textarea.error {
  background-color: rgba(255, 51, 102, 0.1) !important;
  border: 1px solid #ff3366 !important;
}

#post-product-comment-form input.valid,
#post-product-comment-form textarea.valid {
  border: 1px solid #00e676 !important;
}

/* ۵. لیست نظرات و کارت‌های اختصاصی نظردهی */
#product-comments-list-header {
  padding: 16px 18px;
  color: #ffffff;
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  justify-content: space-between;
  border-bottom: 1px solid #1f293d;
  font-size: 15px;
  font-weight: 700;
}

#product-comments-list-header .comments-nb {
  padding-left: 0;
  padding-top: 3px;
  color: #00f2fe;
}

#product-comments-list-header .comments-nb .material-icons {
  margin-right: 4px;
  vertical-align: middle;
}

#product-comments-list .btn-comment {
  margin: 15px auto;
  display: block;
}

.product-comment-list-item {
  padding: 22px;
  margin: 0 0 16px;
  background-color: #131924;
  border: 1px solid #1f2a3d;
  border-radius: 12px;
  text-align: left;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.35);
  transition: border-color 0.3s ease;
}

.product-comment-list-item:hover {
  border-color: rgba(0, 136, 255, 0.4);
}

#empty-product-comment {
  text-align: center;
  color: #798b9e;
  padding: 25px 0;
}

.product-comment-list-item .grade-stars .star-content {
  margin: 0 0 10px;
}

.product-comment-list-item .comment-infos {
  color: #798b9e;
  font-size: 13px;
  line-height: 19px;
  min-height: auto;
}

.product-comment-list-item .comment-infos .grade-stars {
  margin-bottom: 12px;
}

.product-comment-list-item .comment-content .h4 {
  color: #ffffff;
  font-size: 15.5px;
  font-weight: 700;
  letter-spacing: -0.2px;
  line-height: 22px;
  margin-bottom: 8px;
}

.product-comment-list-item .comment-content p {
  color: #cbd5e1;
  font-size: 13.5px;
  line-height: 1.6;
  word-break: break-word;
  white-space: pre-wrap;
}

.product-comment-list-item .comment-content .comment-buttons a {
  color: #798b9e;
  font-size: 13px;
  line-height: 19px;
  margin-right: 12px;
  transition: color 0.2s ease;
}

.product-comment-list-item .comment-content .comment-buttons a:hover {
  color: #00f2fe;
}

.product-comment-list-item .comment-content .comment-buttons a .material-icons {
  font-size: 17px;
  cursor: pointer;
  vertical-align: text-bottom;
}

/* ۶. پیش‌نمایش سریع (Quickview) */
.product-quickview-review {
  display: flex;
  flex-direction: row;
}

.product-quickview-review .grade-stars .star-content {
  margin: 0;
  top: 0;
}

/* ۷. لایه نظرات روی ویترین محصولات */
.product-list-reviews {
  position: absolute;
  top: -26px;
  left: 0;
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  justify-content: center;
  width: 100%;
  background: rgba(11, 14, 20, 0.85);
  backdrop-filter: blur(4px);
  border-radius: 6px;
  padding: 4px 0;
  visibility: hidden;
  border: 1px solid rgba(0, 242, 254, 0.2);
}

.product-list-reviews .grade-stars .star-content {
  top: 1px;
}

.product-list-reviews .comments-nb {
  margin-left: 5px;
  font-size: 12px;
  color: #00f2fe;
}

/* ۸. صفحه‌بندی نظرات (Pagination) */
#product-comments-list-pagination {
  height: 34px;
}

#product-comments-list-pagination ul {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  gap: 4px;
}

#product-comments-list-pagination ul li span {
  height: 34px;
  min-width: 32px;
  padding: 0 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: #cbd5e1;
  background-color: #17202e;
  border: 1px solid #29384d;
  border-radius: 6px;
  transition: all 0.2s ease;
}

#product-comments-list-pagination ul li span:hover {
  border-color: #00f2fe;
  color: #ffffff;
  box-shadow: 0 0 8px rgba(0, 242, 254, 0.2);
}

#product-comments-list-pagination ul li.active span {
  background: linear-gradient(135deg, #0088ff, #0044ff) !important;
  color: #ffffff !important;
  border-color: transparent !important;
  font-weight: 700;
  cursor: default;
}

#product-comments-list-pagination ul li.disabled span {
  opacity: 0.35;
  cursor: not-allowed;
  border-color: #1f293d;
}

#product-comments-list-pagination ul li.hidden {
  display: none;
}

@media (min-width: 960px) {
  #product-comments-list-footer {
    position: relative;
    min-height: 45px;
  }

  #product-comments-list-footer .post-product-comment {
    margin: 0 auto;
    display: block;
  }

  #product-comments-list-pagination {
    position: absolute;
    right: 0;
    top: 5px;
  }
}

@media (max-width: 960px) {
  #product-comments-list-footer {
    display: flex;
    flex-direction: row-reverse;
    flex-wrap: nowrap;
    justify-content: space-between;
  }
}

@media (max-width: 768px) {
  #product-comments-list-footer {
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
    align-items: center;
    gap: 12px;
  }

  #product-comments-list-pagination {
    margin-bottom: 10px;
  }
}
