/* ============================================================
   REVIEWS & RATINGS CSS
   Matches YES Fashion Hub green theme (#0c5a34)
   Mobile-first, fully responsive
============================================================ */

/* ─── REVIEW SECTION WRAPPER ─── */
#reviewSection {
  padding: 28px 0 36px;
  background: #f9fff9;
}

#reviewSection .sectionTitle {
  margin-bottom: 6px;
}

.review-subtitle {
  text-align: center;
  font-size: 13px;
  color: #888;
  margin-bottom: 20px;
}

/* ─── OVERALL RATING SUMMARY ─── */
.rating-summary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  background: #fff;
  border-radius: 16px;
  padding: 18px 20px;
  margin: 0 14px 24px;
  box-shadow: 0 4px 20px rgba(12,90,52,0.08);
  flex-wrap: wrap;
}

.rating-big {
  text-align: center;
}

.rating-big .score {
  font-size: 52px;
  font-weight: 800;
  color: #0c5a34;
  line-height: 1;
}

.rating-big .stars-display {
  font-size: 22px;
  color: #f5a623;
  letter-spacing: 2px;
  margin: 4px 0;
}

.rating-big .total-reviews {
  font-size: 12px;
  color: #888;
}

.rating-bars {
  flex: 1;
  min-width: 160px;
  max-width: 260px;
}

.rating-bar-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 5px;
}

.rating-bar-row .bar-label {
  font-size: 12px;
  color: #555;
  width: 32px;
  flex-shrink: 0;
}

.rating-bar-row .bar-label i {
  color: #f5a623;
  font-size: 10px;
}

.bar-track {
  flex: 1;
  height: 7px;
  background: #e8e8e8;
  border-radius: 99px;
  overflow: hidden;
}

.bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #0c5a34, #44c46d);
  border-radius: 99px;
  transition: width 0.6s ease;
}

.bar-count {
  font-size: 11px;
  color: #888;
  width: 20px;
  text-align: right;
  flex-shrink: 0;
}

/* ─── REVIEWS SLIDER ─── */
.reviews-slider-wrap {
  position: relative;
  margin: 0 0 24px;
}

.reviews-track {
  display: flex;
  overflow-x: auto;
  gap: 14px;
  padding: 4px 14px 12px;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.reviews-track::-webkit-scrollbar { display: none; }

/* ─── REVIEW CARD ─── */
.review-card {
  flex: 0 0 280px;
  background: #fff;
  border-radius: 16px;
  padding: 16px;
  box-shadow: 0 4px 18px rgba(12,90,52,0.08);
  border: 1px solid #edf7ed;
  position: relative;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.review-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 28px rgba(12,90,52,0.13);
}

.review-card-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.reviewer-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, #0c5a34, #44c46d);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 700;
  font-size: 16px;
  flex-shrink: 0;
}

.reviewer-info .reviewer-name {
  font-weight: 700;
  font-size: 14px;
  color: #111;
}

.reviewer-info .review-date {
  font-size: 11px;
  color: #aaa;
}

.review-stars {
  color: #f5a623;
  font-size: 14px;
  letter-spacing: 1px;
  margin-bottom: 8px;
}

.review-text {
  font-size: 13px;
  color: #444;
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.review-verified {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: #0c5a34;
  margin-top: 10px;
  font-weight: 600;
}

.review-verified i {
  font-size: 10px;
}

/* Slider arrows */
.review-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #fff;
  border: 1px solid #e0e0e0;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: #0c5a34;
  z-index: 2;
  transition: all 0.2s;
}

.review-arrow:hover {
  background: #0c5a34;
  color: #fff;
  border-color: #0c5a34;
}

.review-arrow.left { left: 2px; }
.review-arrow.right { right: 2px; }

/* ─── WRITE REVIEW BUTTON ─── */
.write-review-btn {
  display: block;
  width: calc(100% - 28px);
  max-width: 400px;
  margin: 0 auto;
  padding: 13px;
  background: #0c5a34;
  color: #fff;
  border: none;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 700;
  font-family: 'Poppins', sans-serif;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: background 0.2s, transform 0.15s;
}

.write-review-btn:hover {
  background: #0a4a2a;
  transform: translateY(-1px);
}

/* ─── REVIEW FORM MODAL ─── */
.review-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  display: none;
  align-items: flex-end;
  justify-content: center;
  z-index: 99999;
  backdrop-filter: blur(3px);
}

.review-modal-overlay.show {
  display: flex;
}

.review-modal-box {
  background: #fff;
  border-radius: 24px 24px 0 0;
  padding: 24px 20px 32px;
  width: 100%;
  max-width: 540px;
  max-height: 92vh;
  overflow-y: auto;
  animation: slideUp 0.3s ease;
}

@keyframes slideUp {
  from { transform: translateY(100%); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

.review-modal-handle {
  width: 40px;
  height: 4px;
  background: #e0e0e0;
  border-radius: 99px;
  margin: 0 auto 20px;
}

.review-modal-title {
  font-size: 18px;
  font-weight: 800;
  color: #111;
  text-align: center;
  margin-bottom: 20px;
}

/* Star selector */
.star-selector {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 20px;
}

.star-selector .star-btn {
  font-size: 36px;
  background: none;
  border: none;
  cursor: pointer;
  transition: transform 0.15s;
  filter: grayscale(1);
  opacity: 0.4;
}

.star-selector .star-btn.active {
  filter: grayscale(0);
  opacity: 1;
  transform: scale(1.15);
}

.star-selector .star-btn:hover {
  transform: scale(1.2);
}

/* Form fields */
.review-form-group {
  margin-bottom: 14px;
}

.review-form-group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #444;
  margin-bottom: 6px;
}

.review-form-group input,
.review-form-group textarea {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid #e0e0e0;
  border-radius: 10px;
  font-size: 14px;
  font-family: 'Poppins', sans-serif;
  outline: none;
  background: #f9f9f9;
  box-sizing: border-box;
  transition: border-color 0.2s;
}

.review-form-group input:focus,
.review-form-group textarea:focus {
  border-color: #0c5a34;
  background: #fff;
}

.review-form-group textarea {
  resize: vertical;
  min-height: 90px;
}

.review-submit-btn {
  width: 100%;
  padding: 14px;
  background: #0c5a34;
  color: #fff;
  border: none;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 700;
  font-family: 'Poppins', sans-serif;
  cursor: pointer;
  margin-top: 6px;
  transition: background 0.2s;
}

.review-submit-btn:hover { background: #0a4a2a; }
.review-submit-btn:disabled { background: #aaa; cursor: not-allowed; }

.review-close-btn {
  position: absolute;
  top: 16px;
  right: 16px;
  background: #f0f0f0;
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #555;
}

.review-modal-box { position: relative; }

/* ─── SUCCESS STATE ─── */
.review-success {
  text-align: center;
  padding: 20px 0;
  display: none;
}

.review-success .success-icon {
  font-size: 52px;
  margin-bottom: 12px;
}

.review-success h3 {
  font-size: 18px;
  font-weight: 800;
  color: #0c5a34;
  margin-bottom: 8px;
}

.review-success p {
  font-size: 13px;
  color: #888;
}

/* ─── EMPTY STATE ─── */
.reviews-empty {
  text-align: center;
  padding: 30px 20px;
  color: #aaa;
  font-size: 14px;
}

.reviews-empty i {
  font-size: 36px;
  display: block;
  margin-bottom: 10px;
  opacity: 0.4;
}

/* ─── ADMIN REVIEW MANAGEMENT (dashboard) ─── */
.review-mgmt-card {
  background: #fff;
  border: 1px solid #eee;
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 12px;
}

.review-mgmt-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  flex-wrap: wrap;
}

.review-mgmt-name {
  font-weight: 700;
  font-size: 14px;
}

.review-mgmt-stars {
  color: #f5a623;
  font-size: 13px;
}

.review-mgmt-text {
  font-size: 13px;
  color: #555;
  margin: 8px 0;
  line-height: 1.5;
}

.review-mgmt-actions {
  display: flex;
  gap: 8px;
}

.btn-approve {
  background: rgba(12,90,52,0.1);
  color: #0c5a34;
  border: 1px solid #0c5a34;
  padding: 5px 14px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}

.btn-reject {
  background: rgba(224,82,82,0.1);
  color: #e05252;
  border: 1px solid #e05252;
  padding: 5px 14px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}

/* ─── MOBILE RESPONSIVE ─── */
@media (max-width: 480px) {
  .rating-summary {
    gap: 14px;
    padding: 14px;
    margin: 0 10px 20px;
  }

  .rating-big .score { font-size: 44px; }

  .review-card { flex: 0 0 240px; }

  .review-modal-box { padding: 20px 16px 28px; }
}
